Extract Raster Value into Polygon Attribute
I have Raster Data for a State which has Elevation Data in its pixels. I also have Vector layer which has the 300 divisions of State. what I need is, I want to get the average elevation value of particular division from the raster data using ArcGIS.
I tried extract by mask in ArcGIS to extract individual polygon to clip the raster into 300 raster then from individual raster i have collected average elevation but it has taken days together to complete the work. is there any other easy way to get it.
If you have a new question, please ask it by clicking the Ask Question button. Include a link to this question if it helps provide context.
There are several ways to do this. If you don't have Spatial Analyst you can do it anyway as follows:
First, convert the raster to Points using the
Raster to Pointtool. This gives you a grid of points and is relatively quick - 16million points were created in about 2 minutes (be sure to turn off rendering so they aren't displayed though ;-) ).
Now, use the Analysis Tools -> Overlay - Spatial Join tool. Target feature is your 300 polygon layer, join is the point layer. Leave as one-to-one. Create a "Field Map of Join Features" - being sure to set the merge rule as "mean", "Median", or "mode" (or all of them I guess). Resultant single polygon layer should have all 300 polygon areas, each of which has attributes with the requested types of average calculated in them.
That should get you the numbers you need with minimal effort (though waiting quite a bit of processing - Spatial Joins are slow).
This is the task for the Zonal Statistics tool. Go to Spatial Analyst Tools > Zonal > Zonal Statistics and select the Mean statistic. The raster should have an attribute table for this.
(+1) Another note: The processing recommended here by nadya will only take seconds (or fractions thereof), not minutes. The principle involved is that when you're analyzing raster data, using raster procedures (which of course requires raster software like SA) tends to be far more efficient (in its use of your time, the computer's time, and the computer's RAM) than converting rasters to vector format and using vector procedures.
I Hearty Thank you "NADYA" It works but the elevation results changes from 10m to 100m if i compare this with my separate cliped raster result (I tried extract by mask in ArcGIS to extract individual polygon to clip the raster into 300 raster then from individual raster i have collected average elevation but it has taken days together to complete the work. is there any other easy way to get it.)
I was doing this same task but the output zonal summary table does not contain all the features from the zones shapefile. How is this possible? The raster covers every single zone feature and I also selected ignore null values while running the tool.
Hmm, when I do this using the Zonal Statistics tool, it creates a new raster, and doesn't append the maximum (or average, but I'm looking for a maximum values) to the vector layer layer's attribute table. I have had to use the Zonal Statistics as Table tool and then perform a spatial join between the resulting table and the original vector layer.
You can use Geospatial Modelling Environment tools (independent tools) which used to be Hawths Tools. From there you can extract raster values of the extent of polygons with whichever statistics you want. You can also extract thematic variables with its fraction. the result will be automatically added to your shapefile. This tool works together with ArcGIS and R.
Specifically use the isectpolyrst tool to put underlying raster information into polygon shapefiles. It has no problems with overlapping polygons either.