![]() SelectLayerByAttribute_management ( "lyr", "SUBSET_SELECTION", ' "population" > 10000 ' ) # Write the selected features to a new featureclass arcpy. SelectLayerByLocation_management ( "lyr", "intersect", "chihuahua", 0, "new_selection" ) # Within selected features, further select only those cities which have a population > 10,000 arcpy. MakeFeatureLayer_management ( "cities", "lyr" ) # Select all cities which overlap the chihuahua polygon arcpy. workspace = "c:/data/mexico.gdb" # Make a layer from the feature class arcpy. Use data queries to extract features Use the ArcMap Select By Attributes dialog box Here you will use ArcMap's Select By Attributes function to create a. ![]() # Name: ExtactFeaturesByLocationAndAttribute.py # Description: Extract features to a new feature class based on a spatial relationships to another layer AND an attribute query # Import system modules import arcpy # Set the workspace env. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |