gw.zi.cv {lctools} | R Documentation |
A specific version of the function gw.zi
Description
A specific version of the function gw.zi
returning only the leave-one-out Cross Validation (CV) score. gw.zi.cv
exludes the observation for which a sub-model fits.
Usage
gw.zi.cv(bw, formula, family, dframe, obs, kernel, dmatrix, ...)
Arguments
bw |
a positive number that may be an integer in the case of an "adaptive kernel" or a real in the case of a "fixed kernel". In the first case the integer denotes the number of nearest neighbours, whereas in the latter case the real number refers to the bandwidth (in meters if the coordinates provided are Cartesian). This argument can be also the result of a bandwidth selection algorithm such as those available in the function |
formula |
the local model to be fitted using the same syntax used in the zeroinfl function of the R package |
family |
a specification of the count model family to be used in the local model as in the |
dframe |
a numeric data frame of at least two suitable variables (one dependent and one independent) |
obs |
number of observations in the global dataset |
kernel |
the kernel to be used in the regression. Options are "adaptive" or "fixed". The weighting scheme used here is defined by the bi-square function |
dmatrix |
eucledian distance matrix between the observations |
... |
more arguments for the |
Details
Only used by gw.zi.bw
Value
Leave-one-out Cross Validation (CV) score
Author(s)
Stamatis Kalogirou <stamatis.science@gmail.com>
References
Kalogirou, S. (2016) Destination Choice of Athenians: an application of geographically weighted versions of standard and zero inflated Poisson spatial interaction models, Geographical Analysis, 48(2),pp. 191-230. DOI: 10.1111/gean.12092 https://onlinelibrary.wiley.com/doi/abs/10.1111/gean.12092