mImputeLessThans: Impute Censored Values

View source: R/mImputeLessThans.R

mImputeLessThansR Documentation

Impute Censored Values

Description

Imputes substitute values left-censored values multiple times using the data augmentation method.

Usage

mImputeLessThans(..., m = 10, initial = c("lrEM", "complete.obs",
  "multRepl"))

## Default S3 method:
mImputeLessThans(..., m = 10, initial = c("lrEM",
  "complete.obs", "multRepl"))

## S3 method for class 'data.frame'
mImputeLessThans(..., group = NULL, m = 10,
  initial = c("lrEM", "complete.obs", "multRepl"))

Arguments

...

either a data frame that contains columns of class "qw" or any combination of individual vectors of class "numeric," "lcens," or "qw." Missing values are removed before processing.

m

the number of multiple imputations desired.

initial

the method to use for the initial log-ratio covariance matrix, either "lrEM" that uses expectation maximization to construct the matrix, "complete.obs" that uses only the rows with no censored data to construct the matrix, or "multRepl" that uses simple substitution of censored values to compute the matrix. See lrDA for details.

group

character string, the name of the column in the data frame to indicate a group for imputation. See Details

Details

Imputation of left-censored data requires the assumption of multivariate log-normality for a single population. If the data represent samples from multiple populations, then they should be identified by the group argument. The minimum size for any group is 3.

Value

A list of length m containing data frames with imputed censored values. If group is used, then the returned object is a tagged list with names corresponding to the values in the grouping column. Each group contains the m repititions of imputed values.

See Also

lrDA, imputeLessThans


USGS-R/smwrQW documentation built on Oct. 11, 2022, 6:13 a.m.