I'm trying to get a Height Profile for a certain route using the profile tool (terrain profile). Does anyone know how i can get the slope in percent and in degrees in the table of the profile tool so that i can export it?
3 Answers
At 3.8.3, here's what works for me:
I have a raster DEM and a vector point shapefile (the point shapefile does not have elevation values in its attribute table). I want to create an slope profile that follows the point shapefile, utilizing the underlying DEM elevation values:
- Start the Profile tool.
- Click the DEM in the QGIS Table of Contents.
- In the Profile Tool, click the Add Layer button. The highlighted DEM automatically appears in the tool.
- Click the vector point shapefile in the QGIS TOC.
- In the Profile Tool > Options pane, click the drop-down and select Selected Layer. The elevation profile is displayed in the Tool's graph.
- Click the dropdown in the tool's lower-left corner and select Slope (%) or Slope(o). Voila! The slope profile is now displayed, as shown here:
Note: Resorting the shapefile points in a different order had no effect on the profile graph display. From this, it appears that the Profile Tool displays the elevation graph in the order that the points were originally digitized.
-
Adding to Stu Smith's explanation, the Profile tool also lets you: - pan inside the graphic (click & drag); - zoom inside the graphic (mouse scroll); - see on the map the location of the cross-hair in the graphic along the route; - Generate a table of heights along the track (Table tab).– AlbertCommented Apr 23, 2020 at 17:26
I do not know if Profile Tool
(Terrain Profile
) has the ability to export slope data (although it does show slope as a graph).
There are several tools/plugins for QGIS which can calculate DEM profiles... I would suggest qProf plugin.
To export slope, calculate profile first, then go to Export
tab and select topographic profile data
. In the output csv you will find dirslop
column (directional slope) among others.
-
Profile tool only exports point elevation data XYZ (to clipboard or a points layer), but not slope (but you can add that yourself). Your way sounds easier! Commented Aug 10, 2018 at 16:33
-
Thanks @StevenKay Calculating directional slope from xyz requires mathematical skill (head-scratching...) so I've given up quickly.– KazuhitoCommented Aug 10, 2018 at 21:23
You could copy the data to clip board from table tab (with or without coordinates). And paste it in text or CSV format as your wish.