View source: R/SegLocal-class.R
SegLocal | R Documentation |
Create a new object of SegLocal-class
from a matrix of coordinates and population data.
SegLocal(coords, data, env, proj4string = CRS(as.character(NA)))
coords |
a numeric matrix or data frame with coordinates (each row is a point). |
data |
an object of class |
env |
an object of class |
proj4string |
an optional projection string of class |
An object of SegLocal-class
.
Seong-Yun Hong
SegLocal-class
, localenv
# creates a random data set with 50 data points and 3 population groups
xy <- matrix(runif(100), ncol = 2)
colnames(xy) <- c("x", "y")
pop <- matrix(runif(150), ncol = 3)
colnames(pop) <- LETTERS[1:3]
# constructs an object of class 'SegLocal'
v <- SegLocal(coords = xy, data = pop, env = pop)
is(v)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.