I have a raster layer (DTM of central Scotland) and a vector layer that shows the location of archaeological sites. I want to know how to join the layers so that I can figure out what height each archaeological site is at.

I have tried converting the raster layer into a vector layer and then doing a spatial joint but that does not seem to be working since when I polygonise the layer I seem to lose information.

Does anyone know how to "ask" QGIS what sites fall within what height or how to join a raster and a vector layer?


I am not sure if it really solves your issue, but I just read in another post about Zonal Statistics. Might that help? https://docs.qgis.org/2.18/en/docs/user_manual/plugins/plugins_zonal_statistics.html

Otherwise maybe the point sampling tool might help you. There you can extract the values in a point-grid of the raster file. And afterwards you could join the two polygones maybe? http://www.digital-geography.com/qgis-plugins-point-sampling-tool/

Good luck with it :)


In case your archeological data are points, you might able to use v.what.rast.points from the GRASS processing toolbox.

The first thing is to have a field in the location vector to sotre the elevation data.

In my example I have a layer caled ponts and I add a field called z (a double with 3 decimals)

enter image description here

Then use the GRASS command v.what.rast.points as in the picture below. When I tried I had some trobles with the whereargument, but then I just put a 1 state it is always true.

I left the parameter Sampled empty, so a new temporary layer was created. You could also overwrite the vector file with points, but it is a bit risky to try tools for the very first time with your data, better the long way.

enter image description here

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.