RegSDCgen {RegSDC} | R Documentation |
Regression-based SDC Tools - General data generation
Description
IPSO by QR or SVD, scores from arbitrary data, and ROMM
Usage
RegSDCgen(
y,
x = NULL,
doSVD = FALSE,
yNew = NULL,
lambda = Inf,
makeunique = TRUE,
ensureIntercept = TRUE,
returnParts = FALSE
)
Arguments
y |
Matrix of confidential variables |
x |
Matrix of non-confidential variables |
doSVD |
SVD when TRUE and QR when FALSE |
yNew |
Matrix of y-data for new scores (simulated when NULL) |
lambda |
ROMM parameter |
makeunique |
Parameter to be used in GenQR |
ensureIntercept |
Whether to ensure/include a constant term. Non-NULL x is subjected to |
returnParts |
Alternative output two matrices: yHat (fitted) and yRes (generated residuals). |
Details
doSVD has effect on decomposition of y and yNew. Input matrices are subjected to EnsureMatrix
.
Value
Generated version of y
Author(s)
Øyvind Langsrud
Examples
exY <- matrix(rnorm(15), 5, 3)
RegSDCgen(exY)
RegSDCgen(exY, yNew = exY + 0.001 * matrix(rnorm(15), 5, 3)) # Close to exY
RegSDCgen(exY, lambda = 0.001) # Close to exY
[Package RegSDC version 0.7.0 Index]