gsdvar {SecDim} | R Documentation |
Generating second-dimension variables for a spatial variable
Description
Generating second-dimension variables for a spatial variable
Usage
gsdvar(
pointlocation,
gridlocation,
gridvar,
distbuf = seq(1, 10, 1),
quantileprob = seq(0, 1, 0.1)
)
Arguments
pointlocation |
A matrix or data frame of point locations |
gridlocation |
A matrix or data frame of grid locations |
gridvar |
A matrix or data frame of grid variables |
distbuf |
A vector of distance buffer values |
quantileprob |
A vector of quantile probability values |
Value
A data frame containing the selected variables for the second dimension
Examples
data(obs)
data(grids)
pointlocation <- obs[sample(nrow(obs), 20), c("Lon", "Lat")]
gridlocation <- grids[, c("Lon", "Lat")]
gridvar <- grids$Elevation
system.time({
sdavars <- gsdvar(pointlocation, gridlocation, gridvar,
distbuf = c(1, 2, 3), quantileprob = c(0, 0.5, 1))
})
[Package SecDim version 3.2 Index]