cvam-package: Coarsened Variable Modeling

cvam-packageR Documentation

Coarsened Variable Modeling

Description

Extends R's implementation of categorical variables (factors) to handle coarsened observations; implements log-linear models for coarsened categorical data, including latent-class models. Detailed information and examples are provided in the package vignettes.

Details

Log-linear models, when applied to frequencies in a multiway table, describe associations among the factors that define the dimensions of the table. Standard functions for fitting log-linear models in R, including glm and loglin, cannot accept observations with incomplete information on any of the factors in the model, because those observations cannot be assigned with certainty to a single cell of the complete-data table. The functions in the cvam package facilitate log-linear modeling of factors with missing and coarsened values. The two major functions are:

   coarsened     Create a coarsened factor
   cvam          Log-linear models for coarsened factors

A coarsened factor is an extended version of a factor whose elements may be fully observed, partially observed or missing. The partially-observed and missing states are represented by extra levels which are interpreted as groupings of the fully observed states. The cvam function fits log-linear models to coarsened factors. It also accepts ordinary factors with or without missing values, and factors that contain only missing values, which are useful for latent-class analysis. The modeling routines implemented in cvam include EM algorithms for mode finding and Markov chain Monte Carlo procedures for Bayesian simulation and multiple imputation. Supporting funtions are used to extract information from a fitted model, including:

   anova          Compare the fit of cvam models
   cvamEstimate   Estimated marginal and conditional probabilities
   cvamPredict    Predict missing or coarsened values
   cvamLik        Likelihood of observed data patterns
   cvamImpute     Impute missing or coarsened values

Five datasets are also provided:

   abortion2000        Abortion attitudes from the General Social Survey
   crime               Crime victimization data
   hivtest             HIV test dataset
   microUCBAdmissions  U.C. Berkeley graduate admissions microdata
   seatbelt            Seatbelt data

Author(s)

Joseph L. Schafer <Joseph.L.Schafer@census.gov>

Maintainer: Joseph L. Schafer <Joseph.L.Schafer@census.gov>

References

Extended descriptions and examples for all major functions are provided in two vignettes, Understanding Coarsened Factors in cvam and Log-Linear Modeling with Missing and Coarsened Values Using the cvam Package.


cvam documentation built on March 7, 2023, 5:29 p.m.