artifNA.cv {wNNSel} | R Documentation |
This function introduces additional missing values in a missing data matrix artificially. The missing values are introduced under missing completely at random (MCAR) mechanism.
artifNA.cv(x, testNA.prop = 0.1)
x |
a matrix, in which missing values are to be created. |
testNA.prop |
proportion of missing values |
a list contatining a matrix with artifical missing values, removed indices and the provided x matrix
set.seed(3)
x = matrix(rnorm(100),10,10)
## create 10% missing values in x
x.miss<- artifNA(x, 0.10)
## create another 10% missing values in x
x.miss.cv<- artifNA.cv(x, 0.10)
summary(x.miss)
summary(x.miss.cv)