findMissingPattern {bipd}R Documentation

Find missing data pattern in a given data

Description

Find missing data pattern in a given data i.e. whether variables are systematically missing or sporadically missing. Also calculates missing count and percentage for exploratory purposes.

Usage

findMissingPattern(
  dataset = NULL,
  covariates = NULL,
  typeofvar = NULL,
  studyname = NULL,
  treatmentname = NULL,
  outcomename = NULL
)

Arguments

dataset

data which contains variables of interests

covariates

vector of variable names that the user is interested in finding a missing data pattern

typeofvar

type of covariate variables; should be a vector of these values: "continuous", "binary", or "count". Order should follow that of covariates parameter.

studyname

study name in the data specified

treatmentname

treatment name in the data specified

outcomename

outcome name in the data specified

Value

missingcount

missing number of patients for each study and covariate

missingpercent

missing percentage of patients for each study and covariate

sys_missing

a vector indicating whether each covariate is systematically missing

spor_missing

a vector indicating whether each covariate is sporadically missing

sys_covariates

a vector of systematically missing covariates

spor_covariates

a vector of sporadically missing covariates

without_sys_covariates

a vector of covariates that are not systematically missing

covariates

vector of variable names that the user is interested in finding a missing data pattern

studyname

study name in the data specified

treatmentname

treatment name in the data specified

outcomename

outcome name in the data specified

Examples

simulated_dataset <- generate_sysmiss_ipdma_example(Nstudies = 10, Ncov = 5, sys_missing_prob = 0.3, 
magnitude = 0.2, heterogeneity = 0.1)

missP <- findMissingPattern(simulated_dataset, covariates = c("x1", "x2", "x3", "x4", "x5"), 
typeofvar = c("continuous", "binary", "binary", "continuous", "continuous"), studyname = "study",  
treatmentname = "treat", outcomename = "y")
missP


[Package bipd version 0.3 Index]