gvf.misc | R Documentation |
These methods extract information from fitted GVF model(s).
## S3 method for class 'gvf.fit'
coef(object, ...)
## S3 method for class 'gvf.fits'
coef(object, ...)
## S3 method for class 'gvf.fit.gr'
coef(object, ...)
## S3 method for class 'gvf.fits.gr'
coef(object, ...)
## S3 method for class 'gvf.fit'
residuals(object, ...)
## S3 method for class 'gvf.fits'
residuals(object, ...)
## S3 method for class 'gvf.fit.gr'
residuals(object, ...)
## S3 method for class 'gvf.fits.gr'
residuals(object, ...)
## S3 method for class 'gvf.fit'
fitted(object, ...)
## S3 method for class 'gvf.fits'
fitted(object, ...)
## S3 method for class 'gvf.fit.gr'
fitted(object, ...)
## S3 method for class 'gvf.fits.gr'
fitted(object, ...)
## S3 method for class 'gvf.fit'
predict(object, ...)
## S3 method for class 'gvf.fits'
predict(object, ...)
## S3 method for class 'gvf.fit.gr'
predict(object, ...)
## S3 method for class 'gvf.fits.gr'
predict(object, ...)
## S3 method for class 'gvf.fit'
effects(object, ...)
## S3 method for class 'gvf.fits'
effects(object, ...)
## S3 method for class 'gvf.fit.gr'
effects(object, ...)
## S3 method for class 'gvf.fits.gr'
effects(object, ...)
## S3 method for class 'gvf.fit'
rstandard(model, ...)
## S3 method for class 'gvf.fits'
rstandard(model, ...)
## S3 method for class 'gvf.fit.gr'
rstandard(model, ...)
## S3 method for class 'gvf.fits.gr'
rstandard(model, ...)
## S3 method for class 'gvf.fit'
rstudent(model, ...)
## S3 method for class 'gvf.fits'
rstudent(model, ...)
## S3 method for class 'gvf.fit.gr'
rstudent(model, ...)
## S3 method for class 'gvf.fits.gr'
rstudent(model, ...)
## S3 method for class 'gvf.fit'
anova(object, ...)
## S3 method for class 'gvf.fits'
anova(object, ...)
## S3 method for class 'gvf.fit.gr'
anova(object, ...)
## S3 method for class 'gvf.fits.gr'
anova(object, ...)
## S3 method for class 'gvf.fit'
vcov(object, ...)
## S3 method for class 'gvf.fits'
vcov(object, ...)
## S3 method for class 'gvf.fit.gr'
vcov(object, ...)
## S3 method for class 'gvf.fits.gr'
vcov(object, ...)
object |
An object containing one or more fitted GVF models (see ‘Usage’ for the allowed classes). |
model |
An object containing one or more fitted GVF models (see ‘Usage’ for the allowed classes). |
... |
Further arguments passed to or from other methods (see corresponding .lm methods). |
These methods can be used to extract information from fitted GVF model(s).
For more details on their usage, please read the help pages of the methods with same name defined on class .lm by package stats (e.g. coef
, fitted
, etc.).
The requested information, wrapped into an R object whose structure depends on the class of the input fitted GVF model(s) (i.e. arguments object
and/or model
).
Diego Zardetto
GVF.db
to manage ReGenesees archive of registered GVF models, gvf.input
and svystat
to prepare the input for GVF model fitting, fit.gvf
to fit GVF models, plot.gvf.fit
to get diagnostic plots for fitted GVF models, drop.gvf.points
to drop alleged outliers from a fitted GVF model and simultaneously refit it, and predictCV
to predict CV values via fitted GVF models.
# Load example data:
data(AF.gvf)
# Inspect available estimates and errors of counts:
head(ee.AF)
summary(ee.AF)
# List available registered GVF models:
GVF.db
## (A) A *single* fitted GVF model ##
# Fit example data to registered GVF model number one:
m <- fit.gvf(ee.AF, 1)
# Extract some information:
coef(m)
fitted(m)
## (B) A *a set* of GVF models fitted to the same data ##
# Fit example data to registered GVF models for frequencies (i.e. number 1:3):
mm <- fit.gvf(ee.AF, 1:3)
# Extract some information:
r.mod <- residuals(mm)
lapply(r.mod, head)
r.sta <- rstandard(mm)
lapply(r.sta, head)
r.stu <- rstudent(mm)
lapply(r.stu, head)
## (C) a *single* GVF model fitted to *grouped* data ##
# We have at our disposal the following survey design object on household data:
exdes
# Use function svystat to prepare *grouped* estimates and errors of counts
# to be fitted separately (here groups are regions):
ee.g <- svystat(exdes, y=~ind, by=~age5c:marstat:sex, combo=3, group=~regcod)
str(ee.g)
# Fit registered GVF model number one separately inside groups:
m.g <- fit.gvf(ee.g, 1)
# Extract some information:
coef(m.g)
fitted(m.g)
## (D) a *set of* GVF models fitted to *grouped* data ##
# Fit all registered GVF models for frequencies (i.e. number 1:3) separately
# inside groups:
mm.g <- fit.gvf(ee.g, 1:3)
# Extract some information:
coef(mm.g)
fitted(mm.g)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.