l.missfill: Impute NA Values for Missing Observations in a Longitudinal...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/l.missfill.R

Description

Imputes NA values for missing (but expected) observations for each participant at each time point in a longitudinal design. In other words, creates a dataframe that includes all possible measurement occasions for each user. Limited use as-is, but a dependency for other missing data functions in this package. Requires missing data to be stored as NA.

Usage

1
l.missfill(data, user_id, time_id)

Arguments

data

dataset stored as dataframe

user_id

the name of the level-2 grouping variable (e.g., person id); can be stored as a factor, numeric, or integer within a dataframe

time_id

if included, will calculate the ICC using an unconditional growth model (i.e., time included in the model as a predictor); should be stored as numeric or integer within a dataframe

Value

returns an imputed dataset with NA values for missing observations

Author(s)

Myles A. Maillet, myles.a.maillet@gmail.com

See Also

l.missbytime

l.missbyid

l.naconvert

Examples

1
new_ds <- l.missfill(data = ds, user_id = 'id', time_id = 'time')

myles-maillet/long.tools documentation built on Jan. 3, 2021, 12:37 a.m.