View source: R/spatial_manipulation.R
attribute.shapefile | R Documentation |
This function will take a SpatialPoints/PolygonsDataFrame and add one attribute fields from a second SpatialPoints/PolygonsDataFrame
attribute.shapefile(
spdf1,
spdf2,
attributefield = NULL,
newfield = NULL,
projection = sp::CRS("+proj=longlat +ellps=GRS80 +datum=NAD83 +no_defs")
)
spdf1 |
A SpatialPoints/PolygonsDataFrame containing the geometry to add an attribute to |
spdf2 |
A SpatialPoints/PolygonsDataFrame containing the geometry to add an attribute from |
attributefield |
The name of the field in |
newfield |
The name of the field in |
projection |
An |
The original SPDF spdf1 with the new field containing the values inherited from spdf2.
attribute.shapefile()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.