Interpolating Point Data (QGIS3)

Interpolation is a commonly used GIS technique to create a continuous surface from discrete points. A lot of real-world phenomena are continuous - elevations, soils, temperatures, etc. If we wanted to model these surfaces for analysis, it is impossible to take measurements throughout the surface. Hence, the field measurements are taken at various points along the surface and the intermediate values are inferred by a process called ‘interpolation’. In QGIS, interpolation is achieved using the built-in Interpolation tools from the Processing toolbox.

Overview of the task

We will take field depth measurements for Lake Arlington in Texas and create an elevation relief map and contours from these measurements.

Other skills you will learn

  • Creating contours from point data.

  • Masking no-data values from a raster layer.

  • Adding labels to a vector layer.

Get the data

Texas Water Development Board provides the shapefiles for completed lake surveys.

Download the 2007-12 survey shapefiles for Lake Arlington.

For convenience, you can directly download the sample data used in this tutorial from link below.

Shapefiles.zip

Data Sources: [TWDB]

Procedure

  1. Open QGIS, in Browser locate and drag the Arlington_Soundings_2007_stpl83.shp the layer to canvas.

../../_images/190.png
  1. A Select Transformation of Arlington_Soundings_2007_stpl83 dialog box will appear, leave the select to default and click OK.

../../_images/239.png
  1. The layer will be added, now locate and drag the Boundary2004_550_stpl83.shp layer to canvas.

../../_images/329.png
  1. The layer will be added to the canvas, now turn off this layer to visualize the Arlington_Soundings_2007_stpl83 .

../../_images/415.png
  1. Click the Zoom In icon and select a small area on the screen. As you zoom closer, you will see the points. Each point represents a reading taken by a Depth Sounder at the location recorded by a DGPS equipment.

../../_images/515.png
  1. Select the Identify tool and click on a point. You will see the Identify Results panel show up on the left with the attribute value of the point. In this case, the ELEVATION attribute contains the depth of the lake at the location. As our task is to create a depth profile and elevation contours, we will use these values as input for the interpolation.

../../_images/615.png
  1. From Browser locate and drag the Islands_2004_550_stpl83.shp layer to canvas.

../../_images/714.png
  1. The layer will be added to the canvas, this layer has the information about the islands in the region which should have a constant elevation (should not be interpolated).

../../_images/814.png
  1. From the Processing Toolbox, search and locate the Interpolation ‣ TIN Interpolation tool. Double-click to launch it.

Σημείωση

Interpolation results can vary significantly based on the method and parameters you choose. QGIS interpolation supports Triangulated Irregular Network (TIN) and Inverse Distance Weighting (IDW) methods for interpolation. The TIN method is commonly used for elevation data whereas the IDW method is used for interpolating other types of data such as mineral concentrations, populations etc. See the Spatial Analysis module of the QGIS documentation for more details.

../../_images/914.png
  1. In the TIN Interpolation dialog box, select Arlington_Soundings_2007_stpl83 as the Vector layer, Elevation as the Interpolation attribute. Then click on the Add icon.

../../_images/1014.png
  1. Now, select Islands_2004_550_stpl83 as the Vector layer, Elevation as the Interpolation attribute. Then click on the Add icon. Now change the Type of the layer as Break lines.

../../_images/1118.png

Σημείωση

A Break line allows us to model sudden interruptions in the elevation while modeling surface layers. Specifying the layer type to be Break lines will tell the interpolation algorithm to use a constant elevation for the islands instead of interpolated values from the points.

  1. In Extent click on the ... and select the Boundary2004_550_stpl83.

../../_images/1215.png
  1. In Output raster size, set the Pixel size X and Pixel size Y to 5. Then click on the ... under Interpolated to save the layer as elevation_tin.tif. Click Run.

../../_images/1314.png
  1. Now a new layer elevation_tin will be added to the canvas.

../../_images/1413.png
  1. From the Processing Toolbox, search and locate the GDAL ‣ Raster extraction ‣ Clip raster by mask layer tool. Double-click to launch it.

../../_images/1512.png
  1. In Clip raster by mask layer dialog box, select elevation_tin as the Input layer, Boundary2004_550_stpl83 as the Mask layer. Then click on the ... under Clipped (mask) to save the layer as elevation_tin_clipped.tif. Click Run.

../../_images/1611.png
  1. Now a new layer elevation_tin_clipped will be added to the canvas. Click on the Open the Layer styling panel icon.

../../_images/1712.png
  1. Set the Symbology to Singleband pseudocolor, click on the arrow in Color ramp and select Invert color ramp, enter 0 in Label precision. Click Classify.

../../_images/1810.png
  1. From the Processing Toolbox, search and locate the GDAL ‣ Raster extraction ‣ Contour tool. Double-click to launch it.

../../_images/198.png
  1. In the Contour dialog box, select elevation_tin_clipped as the Input layer, enter 5.000 in the Interval between contour line. Then click on the ... under Contours to save the layer as contour.gpkg. Click Run.

../../_images/207.png

Σημείωση

The interval is specified in the unit of the CRS of the layer. Our source data is in the EPSG:2276 NAD83 / Texas North Central (ftUS) - so the interval for coutours will be interpreted as 5 feet.

  1. Now a new layer contour will be added to the canvas. Click on the Open the Layer styling panel icon. Switch to Labels.

../../_images/2113.png
  1. Select Single label, in Value choose ELEV.

../../_images/2210.png
  1. Now switch to Placement and change it the Mode as Curved.

../../_images/2310.png
comments powered by Disqus