How to combine multiple spatial polygons into one single spatial polygon.S ShafferOctober 30, 2015Lab 7 ***************************************************************************************If you are trying to combine multiple distinct spatial polygons so that you only have one to work with, using the maptools package allows you to combine using “spRbind”. Install packages needed:
Using downloader and rgdal pull the data of interest into R. In this case, I am interested in looking at a few specific US states.
Separate out the states of interest. For now they are all separate from eachother.
Now the polygons can be combined using spRbind, one by one. First combine Michigan and Ohio into one polygon, and then combine Indiana into that polygon.
Plot the three states together:
0 Comments
|
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
|