Learn R Programming

mapmisc (version 1.5.0)

tpeqd: Two point equidistant projections

Description

Defines map projection

Usage

tpeqd(x, offset=c(0,0))

Arguments

x

A SpatialPoints* object of length 2 or a matrix with two columns.

offset

2 coordinates to define the origin

Value

An object of class CRS.

Details

A coordinate reference system is returned

References

http://en.wikipedia.org/wiki/Two-point_equidistant_projection

See Also

CRS,spTransform

Examples

Run this code
# NOT RUN {
tpeqd(rbind(c(0,0), c(10,50)))

data('netherlands')

tcrs = tpeqd(nldCities[1:2,])
tcrs

if(require('rgdal', quietly=TRUE)) {
nldT = spTransform(nldCities, tcrs)
projection(nldT)

map.new(nldT)
text(nldT,labels=nldT$name)
scaleBar(nldT, 'topright')

}

# }

Run the code above in your browser using DataLab