Operations with Raster Data II
Content for Wednesday, October 4, 2023
Now that we’ve done some “global” transformations of raster data using terra
, we’ll look at some of the options for cell-wise transformations. Rather than manipulating the extent, resolution, or CRS of the raster data; we’ll actually be using functions to change the values of the cells themselves.
Readings
The
terra
package vignette describes the new raster functions available interra
, their relationship to those in theraster
package, and the changes in syntax between the two.The Raster GIS Operations in R with terra chapter from Jasper Slingsby’s “A Minimal Introduction to GIS (in R)” bookdown project has worked examples of many of the operations we’ll learn today.
Objectives
By the end of today, you should be able to:
Use moving windows as a means of smoothing raster data
Reclassify data using conditional statements and reclassification tables
Use raster math as a means of creating new data based on an existing dataset.
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.