Combining Raster and Vector Data
Content for Monday, October 3, 2022
Readings
As we move towards a complete geospatial statistical workflow, we’ll need to be able to combine data from both raster and vector datasets. Sometimes that will mean simply converting from one format to another. In other cases, we’ll need to create new datasets based on calculations that integrate different data models. We’ll do some of that today.
The Integrating rasters and vectors chapter of Michael Dorman’s Introduction to Spatial Data Programming with R online textbook has a number of worked examples combining vector and raster data.
Raster-vector interactions Chapter 6 in Lovelace et al., Geocomputation with R (Lovelace et al. 2019) has a great description of why you might do some of these things in your analysis.
Objectives
By the end of today, you should be able to:
Clip, crop, or extend vector and raster data so that extents align
Convert between raster and vector datasets
Generate new rasters describing the spatial arrangement of vector data
Extract raster values as attributes of vector data
Slides
The slides for today’s lesson are available online as an HTML file. Use the buttons below to open the slides either as an interactive website or as a static PDF (for printing or storing for later). You can also click in the slides below and navigate through them with your left and right arrow keys.
View all slides in new window Download PDF of all slides