Skip to content
Advertisement

Tag: polygon

How to have a poligon in the legend

I have a chart with 4 elements: blue square,blue triangle, red square and red triangle, I’m tryng to add these 4 items to the legend. when I add a polygon patch to the legend, it is displayed as a rectangle, even though the patch is of a triangle How can I get it to work? Answer You could use line

Remove a Polygon from a MultiPolygon with shapely in Python

I am working with spatial objects in Python using the shapely library. Given a MultiPolygon, I want to remove from it the Polygons which don’t contain an obstacle. However, I haven’t found a way to do this, even though I can get the coordinates from the MultiPolygon just by using the mapping function. I already know which Polygons I want

Advertisement