I’ve just installed Anaconda in my new laptop, and created an environment with geopandas installed in it. I’ve tried to upload the world map that comes with geopandas through the following code: But I obtain the following error message: Since this error has never appeared in my old laptop, I guess it is related to some problem during installation, but
Tag: geopandas
geopandas .explore – How to set marker icon?
I want to change the icon of the marker in .explore to a house icon. I have read the documentation of geopandas.GeoDataFrame.explore and folium, still not able to understand it. The icon represents the position of the house and I set colormap base on an integer value. Also, is there a way to make a radius size don’t change when
Geopandas not exploding
Why isn’t geopandas exploding this series??? Below I have posted the first 5 rows. Clearly multilinestring and that function isn’t throwing any errors. Any suggestions? Any other idea’s of how to convert multilinestring to linestring would be appreciated. Answer Quick tip for your next question ;) – since you’ve provided full WKT objects, we actually can create a MRE directly
Data from OSM (overpy) to geodataframe with polygons
I try to put OSM data (some polygons) to geodataframe. Export from OSM contains LineString. But in the end i need to converte all data into geodataframe in this format: 0 -> name_from_tag_first_area -> polygon (or multipolygon) type with coordinates 1 -> name_from_tag_second_area -> polygon (or multipolygon) type with coordinates And then i will use this GeoDataFrame to visualize this
How can you use RD coordinates instead of gps coordinates to plot traffic routes in a folium plot?
In want to show traffic routes on a folium map. These routes are in the Netherlands and the coordinates are in RD (EPSG:28992). I tried to map the routes using the following code: But this won’t work and this results in a random red line: However it does work whenever I transform the RD coordinates to GPS coordinates: This looks
Export properties into .geojson file using geopandas
I have a script that creates a lot of Polygons using Shapely and then exports them as .geojson files. See toy example below However, I also have a list of numbers, each number is associated with one ploygon. Is there a way to export this with the GeoJSON file inside properties? For example, if I have a list: In the
Geopandas: different .sjoin() results with different projections systems
I tried to run a spatial join between a list of assets and a river basin dataset that you can find at the link below https://datasets.wri.org/dataset/aqueduct-global-flood-risk-maps?msclkid=630fc948b63611ec9931936b22cf4990 The first approach was a join on an ESPG 4326 projection setting and it works fine. The two assets have both a join. In a second approach, I try to create a 500 mt
Pandas/Geopandas Merge with a mask selection
I usually work with Arcpy but am trying to learn more pandas/geopandas uses. I have a mask applied to a csv table and a shapefile that I want to merge together in order to find matches between the two based on a specific field. However, when I try to merge them together, I get the error “The truth value of
find nested boxes from huge dataset with geopandas (or other tools)
Basically I have DataFrame with a huge amount of boxes which are defined with xmin ymin xmax ymax tuples. My task is to remove all nested boxes. (I.e. any box which is within another box has to be removed) My current method: construct GeoDataFrame with box geometry sort by box size (descending) iteratively find smaller boxes within a larger box.
Get information from plt.hexbin
I have been using hexbing to try to improve the SPCF method, so for that I would need to get information from the plot to modify the data and then replot it with the new values. The most important data I need to modify to replot is the number of points per cell and the C value of that grid