DMMD_Impute | R Documentation |
An iterative algorithm to do imputation based on iterative DMMD method.
DMMD_Impute( X1, X2, init = c("mean", "unif", "normal"), r1 = NULL, r2 = NULL, rc = NULL, rr = NULL, angle_threshold = 90 * pi/180, variance1 = c("equal", "unequal"), variance2 = c("equal", "unequal"), method = c("PL", "ED"), tol = .Machine$double.eps^0.5, maxiter1 = 1000, maxiter2 = 1000 )
X1 |
The first data matrix with NAs |
X2 |
The second data matrix with NAs |
init |
The imputation method for initializing X1 and X2. Could be 'mean', 'unif' or 'normal'. Default 'mean' |
r1 |
Total rank for X1. Default is NULL, meaning unknown, which will be estimated by rank estimation procedure determined by 'method'. Passed to DMMD_i function |
r2 |
Total rank for X2. Default is NULL, meaning unknown, which will be estimated by rank estimation procedure determined by 'method'. Passed to DMMD_i function |
rc |
Joint column rank. Default is NULL, meaning unknown, which will be estimated by profile likelihood method. Passed to DMMD_i function |
rr |
Joint row rank. Default is NULL, meaning unknown, which will be estimated by profile likelihood method. Passed to DMMD_i function |
angle_threshold |
The threshold angle for principal angles. Principal angles greater than the threshold are not considered as joint signal. Default is 90 degree. Passed to DMMD_i function |
variance1 |
Either "equal" or "unequal". Default is "equal". This argument is the variance assumption used in the profile likelihood method for determining the total rank. Passed to DMMD_i function |
variance2 |
Either "equal" or "unequal". Default is "equal". This argument is the variance assumption used in the profile likelihood method for determining the joint rank. Passed to DMMD_i function |
method |
The method used for determining the total ranks r1 and r2. Either "PL" (profile likelihood) or "ED" (edge distribution). Default is "PL". Passed to DMMD_i function |
tol |
The tolerance used to determine convergence. Default is the square root of the machine precision. Passed to DMMD_i function |
maxiter1 |
Maximum number of iterations allowed in the iterative imputation. Default is 1000 |
maxiter2 |
Maximum number of iterations allowed in each called DMMD_i function. Default is 1000 |
A list with the following elements:
Imputed_X1 |
The final imputed and complete X1 |
Imputed_X2 |
The final imputed and complete X2 |
data = DoubleDataGen(n = 20, p = 16, rank = c(4, 3), rc = 2, rr = 1, nrep = 1) X1_missing = data$X1[[1]] X2_missing = data$X2[[1]] X1_missing[1,1] = NA X2_missing[3,2] = NA result = DMMD_Impute(X1_missing, X2_missing) result$Imputed_X1 - data$X1[[1]]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.