MAR.df: Assign NAs to columns in a dataframe at random

Description Usage Arguments Value Note Author(s)

View source: R/missingness.R

Description

Create a dataframe with data missing at random by generating probability models of missing data from observable characteristics and then eliminating data based on those results.

Usage

1
MAR.df(df, vars, probs)

Arguments

df

a dataframe that missing data should be supplied to

vars

A list of variable names to be used in generating the probability models for the missing data

probs

A single value from 0 to 1 representing the proportion of each column that should be replaced with NAs, or a list of such values length of vars

Value

df with proportion p of values replaced with NA

Note

Yadda yadda yadda

Author(s)

Jared E. Knowles


jknowles/datasynthR documentation built on May 19, 2019, 11:42 a.m.