Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

5/26/2016 Extracting raster DEM elevations to vector attribute tables in ArcGIS Desktop?

 ­ Geographic Information Systems Stack Exchange
     
sign up log in tour help 

_
Geographic Information Systems Stack Here's how it works:
Exchange is a question and answer site
for cartographers, geographers and GIS
professionals. It's 100% free, no
registration required. 
Anybody can ask Anybody can The best answers are voted
Sign up a question answer up and rise to the top

Extracting raster DEM elevations to vector attribute tables in ArcGIS Desktop?

I have an ArcMap 10 project with multiple layer groups. One layer is a raster DEM, another layer group is a bunch of vector shapefiles (including
points, lines and polygons). The client wants all vector data to contain Z values.

Populating the attribute tables for the vector data with X and Y values is easy enough but how do I populate the Z values?

Is there a way that I can use Field Calculator to "grab" the height values from the DEM layer for each vector feature?

I should add that we don't have a licence for the 3D Analyst or Spatial Analyst extensions.

arcgis­desktop   arcgis­10.0   field­calculator   dem

edited Feb 22 at 21:55 asked Jun 26 '12 at 23:40
PolyGeo ♦ Brad Torr
35.8k 9 54 128 46 1 1 2

7 Answers

In ArcGIS, I've only ever done this with point vectors—I'm not sure how you'd do it with polygons
or line features. Unfortunately you do need Spatial Analyst, though. There's a tool at Spatial
Analyst Tools\Extraction\Extract Multi Values to Points and Extract Values to Points.
Extract Multi Values to Points is better because it lets you rename the z field name that you are
extracting your values to—Extract Values to Points doesn't let you do this. I have trouble doing
this in ArcMap (the tool crashes), but it works fine in ArcCatalog.

The (free) Hawths Analysis Tools  extension for ArcMap had an Intersect Point Tool but
development of the extension was discontinued a couple of years ago. It's been superseded by
the Geospatial Modelling Environment, which I've never used.

SAGA­GIS (freeware standalone software) has two functions at Shapes ­ Grid\Add Grid
Values to Points and Shapes ­ Grid\Add Grid Values to Shapes that can probably do what
you want. This is the description of the Add Grid Values to Shapes tool:

Spatial Join: Retrieves information from the selected grids at the positions of the shapes of the
selected shapes layer and adds it to the resulting shapes layer. For points this is similar to
'Add Grid Values to Points' module. For lines and polygons average values will be calculated
from interfering grid cells. For polygons the 'Grid Statistics for Polygons' module offers more
advanced options.

SAGA is your best bet, in my opinion.

Hope this helps!

edited Jun 27 '12 at 2:35 answered Jun 27 '12 at 2:29
npo
698 6 15

1   Geospatial Modeling Environment has the following tools which may do the trick: 1) isectpolyrst (Intersect Polygons
With Raster) 2) isectlinerst (Intersect Lines With Raster) 3) isectpntrst (Intersect Points With Raster). These tools can
be a bit tempermental at times, however they will get the job done. – Aaron ♦ Jun 27 '12 at 2:57

maybe you could use gdallocationinfo to retrive all the Z values by passing it the X,Y values.
once you have the Z values use the feild calculator to add the Z value to the points that make up
each feature. There would be some scripting involved but in theory this should work.

http://gis.stackexchange.com/questions/28298/extracting­raster­dem­elevations­to­vector­attribute­tables­in­arcgis­desktop 1/3
5/26/2016 Extracting raster DEM elevations to vector attribute tables in ArcGIS Desktop? ­ Geographic Information Systems Stack Exchange
answered Jun 27 '12 at 6:21
dango
481 2 12

Depending on your units or required resolution, you could always export the DEM raster into a
polygon shapefile, straight from the toolbox, and then do a spatial join ­ this is easiest for points. If
you need Z values for lines or polygons, you would obviously need defined segments or
subdivisions of polygons at each change in elevation as reported by the vectorized DEM grid.
That can be done via standard geoprocessing tools and spatial joins, but you need to pay close
attention to your resolution requirements and the amount of processing that a large dataset will
consume.

answered Mar 27 '13 at 19:32
Warren
1

I recommend getting a 3D Analyst license and using Add Surface Information. Or, use Interpolate
Shape followed by Add Z Information, which allows some features to return NA values without
crashing the entire program. Otherwise, there are two proven free methods  that require more
legwork. It is possible to implement these from within QGIS, so that you don't have to leave your
comfy GIS environs.

answered Jun 23 '15 at 0:29
Adam Erickson
126 4

I haven't tried this for polygons but it works really well for points. In Arcmap 10 if you have
access to a 3d analyst tool you can search for the Tool Interpolate Shape Then you select your
raster file and your vector layer adjust the z values if you want elevations in feet and your DEM is
in meters and let that run. Once it is complete you then search for the tool ADD XY and select
your newly created layer and it will then calculate your X, Y,Z values in that layers attribute table.

answered Oct 5 '15 at 22:54
Pete
38 4

The ESRI tool you would be looking to use is the "Add Z Information". Perhaps you can get a trial
and see if the tool would be of further use for you. If getting the 3D Analyst extension is not an
option, the only thing that comes to mind (other than a programming solution) is popping your data
out of ESRI and using one of the free options such as SAGA­GIS / qGIS their "Add Grid Value to
Shapes" or "Grid Statistics for Polygons" isn't as flexible as ESRI's but does the same thing if
you're looking for the average height along the polygon / line.

answered Feb 23 at 0:21
user67765
36 1

I know how to do this for points. Lines and polygons are different because they cross multiple grid
cells of the DEM. You can make points along the lines or something like that and extract values
for those. In Arc, you'll need spatial analyst to get the values, but you can get them through Qgis
(free), though not as useful. You'll need to be skilled at working with excel files and converting
them back and forth from shapefiles. The Qgis will generate a shapefile that has only the
extracted point elevations, so you'll need to copy and paste that into your original table as an
excel file (with the X,Y values, so you can make it back int a shapefile with "display x,y data").
You'll need to keep track of your projections to make sure to pick the right one when converting
back to shapefile.

answered Sep 22 '15 at 18:49
Michael
1

    When answering a question, please be specific instead of pointing to different directions. e.g. the user needs an
answer in ArcGIS (not QGIS). – Farid Cher Sep 22 '15 at 19:46

http://gis.stackexchange.com/questions/28298/extracting­raster­dem­elevations­to­vector­attribute­tables­in­arcgis­desktop 2/3
5/26/2016 Extracting raster DEM elevations to vector attribute tables in ArcGIS Desktop? ­ Geographic Information Systems Stack Exchange

http://gis.stackexchange.com/questions/28298/extracting­raster­dem­elevations­to­vector­attribute­tables­in­arcgis­desktop 3/3

You might also like