2

I'm running a spectral mixture analysis project. For my ground truth data, I've created a random points layer, and need to extract the 30x30m LandSat pixels in which the points lay. After that, I'll convert them to polygons.

So, how do I extract JUST those cells with points on them?

I'm using ArcMap 10.3.

To clarify, I'll only be using their shape, location, and orientation when converted to polygons. Their values aren't important (i.e., "Extract Values by Points" is not applicable here).

The "Extract by Points" tool DOES work, but I'd like to figure out a way to add my entire list of points, or just select the point layer, instead of manually copying and pasting all of the X and Y coordinates into the tool and adding them individually.

I'm guessing this is an ideal situation for using ModelBuilder. I have my Input Raster, a .txt file (should I use another format?). I'm stumped from here:

Extract by Points Model

  • Could you please elaborate on why Extract by Points or Extract Multi Values to Points do not work in your case? Are you working with a single raster layer? Is the issue iterating through a group of points? – Aaron Nov 7 '16 at 0:46
  • I'm not trying to extract the values from these points. I don't need the values. I'm simply trying to select the pixels they lay on, and make a new layer from those pixels. – Andy Skeen Nov 7 '16 at 21:44
1

If you are amenable to using python, you could try something like this:

import arcpy
arcpy.CheckOutExtension("Spatial")

raster = #path to landsat imagery
pnts_fc =  r"C:\Default.gdb\points"
#create point list - saves you from creating it manually
pnts_list = [arcpy.Point(row[0],row[1]) for row in arcpy.da.SearchCursor(pnts_fc,["SHAPE@X","SHAPE@Y"])]

extracted_cells =  r"C:\Default.gdb\Extracted_cells"
temp_raster = arcpy.sa.ExtractByPoints(raster,pnts_list),"INSIDE")
temp_raster.save(extracted_cells)
0

Use the Point To Raster tool, and change the Enviroment settings (Cell Size, Extent, Mask, and Output Coordinate System) to match the LandSat image.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.