as.mids.update: Slightly edited version of as.mids() from mice package

Description Usage Arguments

View source: R/as_mids_update.R

Description

The original function relies on data being sorted by .imp to work properly. This is problematic in data sets created manually - say, calculating summary statistics using original + imputed data, where the final data set we want to combine does not have an .imp column. Original function by Stef van Buuren, with detective work and changes by Cole Beck. See this analysis for a full example.

Usage

1
as.mids.update(data, .imp = 1, .id = 2)

Arguments

data

A multiply imputed data set in long format

.imp

Mandatory column indicator for the multiple imputation stream, where 0 indicates the incomplete data and 1 through m indicate the m multiple imputation streams. Default is 1.

.id

Optional column indicator for the row numbers. Default is 2.


jenniferthompson/JTHelpers documentation built on May 19, 2019, 4:04 a.m.