autoMAR: Function to identify and generate the Missing at Random...

View source: R/autoMAR.R

autoMARR Documentation

Function to identify and generate the Missing at Random features (MAR)

Description

This function will automatically identify the missing patterns and flag the variables if they are not missing at random based on the AUC method

Usage

autoMAR(
  data,
  aucv = 0.9,
  strataname = NULL,
  stratasize = NULL,
  mar_method = "glm"
)

Arguments

data

[data.frame | Required] dataframe or data.table

aucv

[integer | Optional] auc cut-off value for the not missing at random variable selection

strataname

[text | Optional] vector of stratification variables

stratasize

[integer | Optional] vector of stratum sample sizes (in the order in which the strata are given in the input dataset).

mar_method

[text | Optional] missing at random classification method ("glm", "rf"). Default GLM is used (GLM runs faster for high dimensional data)

Value

list output including missing variable summary and number of MAR flag variables

Examples

# create missing at random features
marobj <- autoMAR (heart, aucv = 0.9, strataname = NULL, stratasize = NULL, mar_method = "glm")

DriveML documentation built on Dec. 2, 2022, 5:14 p.m.