cooks.distance.spmodel {spmodel} | R Documentation |
Compute Cook's distance
Description
Compute the Cook's distance for each observation from a fitted model object.
Usage
## S3 method for class 'splm'
cooks.distance(model, ...)
## S3 method for class 'spautor'
cooks.distance(model, ...)
## S3 method for class 'spglm'
cooks.distance(model, ...)
## S3 method for class 'spgautor'
cooks.distance(model, ...)
Arguments
model |
A fitted model object from |
... |
Other arguments. Not used (needed for generic consistency). |
Details
Cook's distance measures the influence of an observation on a fitted model object. If an observation is influential, its omission from the data noticeably impacts parameter estimates. The larger the Cook's distance, the larger the influence.
Value
A vector of Cook's distance values for each observation from the fitted model object.
See Also
augment.spmodel()
hatvalues.spmodel()
influence.spmodel()
residuals.spmodel()
Examples
spmod <- splm(z ~ water + tarp,
data = caribou,
spcov_type = "exponential", xcoord = x, ycoord = y
)
cooks.distance(spmod)
[Package spmodel version 0.7.0 Index]