Description Usage Arguments Details Value Author(s) Examples
View source: R/get_projstring.R
helper function used to extract the proj4string of "R" spatial objects or of raster or vector files
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | get_projstring(object, abort = FALSE)
## Default S3 method:
get_projstring(object, abort = FALSE)
## S3 method for class 'character'
get_projstring(object, abort = FALSE)
## S3 method for class 'Raster'
get_projstring(object, abort = FALSE)
## S3 method for class 'sf'
get_projstring(object, abort = FALSE)
## S3 method for class 'sfc'
get_projstring(object, abort = FALSE)
## S3 method for class 'Spatial'
get_projstring(object, abort = FALSE)
|
object |
|
abort |
|
DETAILS
character
proj4string of the object or file
Lorenzo Busetto, phD (2017) lbusett@gmail.com
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
library(raster)
in_rast <- system.file("extdata", "sprawl_EVItest.tif", package = "sprawl.data")
get_projstring(in_rast)
in_rast <- raster::raster(in_rast)
get_projstring(in_rast)
in_vect <- system.file("extdata","lc_polys.shp", package = "sprawl.data")
get_projstring(in_vect)
in_vect <- read_vect(in_vect)
get_projstring(in_vect)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.