AF.gvf: Example Data for GVF Model Fitting

AF.gvfR Documentation

Example Data for GVF Model Fitting

Description

File AF.gvf contains a set of summary statistics that can be used to illustrate ReGenesees facilities for fitting Generalized Variance Functions models. These summary statistics have kind ‘Absolute Frequency’ (see function estimator.kind), i.e. involve estimates and errors of counts.

Usage

data(AF.gvf)

Format

Each row of the ee.AF data frame represents an estimated absolute frequency along with its estimated sampling error (expressed in terms of standard error, coefficient of variation and variance). The data frame has 349 rows, and the following 5 columns:

name

The name of the original estimate, factor with 349 levels.

Y

The value of the original estimate (an absolute frequency), numeric.

SE

The standard error of the original estimate, numeric.

CV

The coefficient of variation of the original estimate, numeric.

VAR

The variance of the original estimate, numeric.

Details

Object AF is a list storing estimates and errors of counts (namely, summary statistics of kind ‘Absolute Frequency’) computed on survey design object exdes. The names of the slots of list AF indicate the nature of the corresponding estimates, e.g. element AF[["sex.marstat"]] stores estimates and errors of the joint absolute frequency distribution of variables sex and marstat (see ‘Examples’).

Object ee.AF is the gvf.input object built upon all such summary statistics, via function gvf.input (see ‘Examples’).

See Also

estimator.kind to assess what kind of estimates are stored inside a survey statistic object, 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.

Examples

data(AF.gvf)

# Inspect object AF
class(AF)
length(AF)
names(AF)
AF$sex.marstat
class(AF$sex.marstat)

# Inspect gvf.input object ee.AF
head(ee.AF)
str(ee.AF)
plot(ee.AF)

# The design object used to compute ee.AF is the following:
exdes

# How has object ee.AF been built?
foo <- gvf.input(exdes, stats = AF)
identical(ee.AF, foo)

DiegoZardetto/ReGenesees documentation built on Dec. 16, 2024, 2:03 p.m.