MVgen: Amputation of a dataset

View source: R/MVgen.R

MVgenR Documentation

Amputation of a dataset

Description

This function is designed to ampute datasets.

Usage

MVgen(dataset, prop_NA)

Arguments

dataset

dataset to be amputed

prop_NA

desired proportion of missing values in the amputed dataset

Value

A dataset with missing values.

References

M. Chion, Ch. Carapito and F. Bertrand (2021). Accounting for multiple imputation-induced variability for differential analysis in mass spectrometry-based label-free quantitative proteomics. arxiv:2108.07086. https://arxiv.org/abs/2108.07086.

Examples

library(mi4p)
data(datasim)
datasim_amp <- MVgen(datasim, .2)
sum(is.na(datasim_amp))/prod(dim(datasim_amp))

mariechion/mi4p documentation built on March 28, 2023, 2:54 p.m.