Learn R Programming

rCAT (version 0.1.6)

trueCOGll: True centre of gravity from a set of Lat longs

Description

Calculates the "true" centre of gravity (weighted) from a set of lat longs, using cartesian geometry

Usage

trueCOGll(thepoints)

Arguments

thepoints

set of points c(lat,long)

Value

a point (lat,long) from centre

References

Descartes, R., 1637. Discours de la methode. A Leyde, De l<U+2019>imprimerie de I. Maire, Paris.

Examples

Run this code
# NOT RUN {
lat <- runif (200,-24,-12)
long <- runif (200,43,51)
ll <- data.frame(lat,long)
cp <- trueCOGll(ll)
# }

Run the code above in your browser using DataLab