compareCRS: Partially compare two CRS objects

Description Usage Arguments Value See Also Examples

View source: R/compareCRS.R

Description

Compare CRS objects

Usage

1
compareCRS(x, y, unknown=FALSE, verbatim=FALSE, verbose=FALSE)

Arguments

x

CRS object, or object from which it can be extracted with projection, or PROJ.4 format character string

y

same as x

unknown

logical. Return TRUE if x or y is TRUE

verbatim

logical. If TRUE compare x and y, verbatim (not partially)

verbose

logical. If TRUE, messages about the comparison may be printed

Value

logical

See Also

sp::identicalCRS, crs

Examples

1
2
3
4
5
6
7
8
9
 
compareCRS("+proj=lcc +lat_1=48 +lat_2=33 +lon_0=-100 +ellps=WGS84",
  "+proj=longlat +datum=WGS84")
compareCRS("+proj=longlat +datum=WGS84 +no_defs +ellps=WGS84 +towgs84=0,0,0",
  "+proj=longlat +datum=WGS84")
compareCRS("+proj=longlat +datum=WGS84 +no_defs +ellps=WGS84 +towgs84=0,0,0", 
  "+proj=longlat +datum=WGS84", verbatim=TRUE)
compareCRS("+proj=longlat +datum=WGS84", NA)
compareCRS("+proj=longlat +datum=WGS84", NA, unknown=TRUE)

raster documentation built on Jan. 5, 2021, 3:01 a.m.