How do you create a new feature class from the select by location tool in python?
This is my script that works but I just don't know what the next step is.
arcpy.SelectLayerByLocation_management("Buildings", "WITHIN_A_DISTANCE", "Hydrography", "50 feet", "NEW_SELECTION","NOT_INVERT")
Best Answer
To do this with python you need to create some variables first so you can call the selection and with the arcpy.CopyFeatures tool copy the selection to a new feature class.
This example was used within the Python interpreter in ArcMap. You can see that by using variables it makes everything easier to use and understand.
The example you provide should be something like this: