Clipping Points to a Raster (extract {raster})Megan KressSeptember 21, 2016
extract FunctionThe extract function extracts data from a Raster object based on the location of another set of spatial data (SpatialPoints, two-column data.frame, SpatialPolygons, etc.). The function comes from the raster package. For more information on the extract function, see the CRAN page for the raster package. For this example, I followed the general structure of Lab 02 (getting species occurrences from GBIF). I used data for the black bear, and clipped it to the outline of the Northeast region.
Preparation (from Lab 02)
Plot All Occurences
Plot Clipped Occurences
0 Comments
Leave a Reply. |
Spatial Ecology @ MSUClick on "Category" below to search for R code compiled by the Zarnetske Spatial & Community Ecology Lab and students in MSU's Spatial Ecology graduate course (FOR870/FW870) Category
All
Archive
October 2016
|