Learn R Programming

mdapack (version 0.0.2)

missingAnalysis: A missingAnalysis Function

Description

'missingAnalysis' function reveals the variables with missing values, the number of missing values for each variable, and in what combinations It also produces a plot for visualizing pattern of missing values and returns a data frame showing correlation between pairs of variables that has missing values It also returns a data frame with complete cases

Usage

missingAnalysis(
  dat,
  plot = FALSE,
  miss_pattern = FALSE,
  complete_dat = FALSE,
  miss_cor_pattern = FALSE
)

Arguments

dat

Data in data frame format.

plot

A plot of the missing data pattern.

miss_pattern

A data frame with missing data pattern for each variable.

complete_dat

A data frame with complete cases.

miss_cor_pattern

Correlation between variables with missing values.

Value

Returns a complete data frame, a tabulation of missing data pattern and missing data plot for combination of variables

Examples

Run this code
# NOT RUN {
library(VIM)
data(sleep)
missingAnalysis(sleep, complete_dat  = TRUE)
# }

Run the code above in your browser using DataLab