Sunday, 12 November 2017

shapefile - Select by attributes within the fiona Python module



Is it possible to select polygons from a shapefile based upon their attributes using the Fiona Python module? I can't seem to find anything in the docs, but it seems like a strange thing not to be included in the module.


All I can think of at the moment is iterating through all the polygons, doing the calculations I want to do, and then storing the data in a database, or some other data structure, and then running my SELECT query over that.


Alternatively if there is another Python module that will do this easily then that would be great to know about.




No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...