Description Usage Arguments Value Author(s) See Also Examples
This function calculates a local neighbourhood to be used for fitting of spatial/spatio-temporal vine copulas and for prediction using spatial/spatio-temporal vine copulas.
1 2 | getNeighbours(dataLocs, predLocs, size = 5, var = names(dataLocs)[1],
coVar=character(), prediction=FALSE, min.dist = 0.01)
|
dataLocs |
some spatial data frame holding the data used for estimation/prediction |
predLocs |
A spatial object defining the prediction locations, might be missing if the neighbourhood is used for fitting |
size |
The size of the neighbourhood including the location of interest (for fitting as well for prediction) |
var |
the variable name of interest, by default the first variable is used |
coVar |
the name of the covariate, if any |
prediction |
whether the neighbourhood should be used for prediction (TRUE) or spatial/Spatio-temporal vine copula fitting |
min.dist |
the minimal distance for a location to be included. Must be larger than 0 for fitting purposes and might be 0 for prediction |
An object of neighbourhood
.
Benedikt Graeler
See neighbourhood
for the native constructor of a neighbourhood
class.
1 2 3 4 5 | library("sp")
spdf <- data.frame(x=c(112,154,212,289,345),y=c(124,198,85,168,346),measure=rlnorm(5))
coordinates(spdf) <- ~x+y
getNeighbours(spdf,size=4)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.