Will extract the coordinate reference system from a SpatialObject and check that it matches a specified reference.

check_crs(input,
  crs_ref = "+proj=longlat +datum=WGS84 +no_defs +ellps=WGS84 +towgs84=0,0,0",
  warn = TRUE)

Arguments

input

an object of spatial class.

crs_ref

the CRS to be compared against. Defaults to WGS84

warn

print a warning message if they do not match. Default is TRUE