From the course: Geospatial Data Analytics Essential Training

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Simple functions and computations

Simple functions and computations

- In the previous section, we saw how to create a geo data frame from scratch. It was stored in the variable called the GDF, which now has five different geometries, a point, a line, a square, and the triangle. In this video, we will quickly learn how to write and apply simple functions on these geometries stored within a single geo data frame. First, to recap what we built before, let's display this geo data frame, which we will explore and modify further in this current video. As you can see here, we have a geo name column storing the English names of the geometries and the geometry column, storing the shapely geometry objects. In the first function, we create a new column in the geo data frame, which stores the type of each geometry using its name in the shapely library. For this, I will use the upline method, which will apply the type query to each element in the geometric column and return the name of the geometry type of that record. Let's call this new column geometry type…

Contents