Description Usage Arguments Value Examples
View source: R/generalized_rc.R
This function computes the imputed values based on a list of error-prone proxies of the true covariate.
1 | generalizedRC(W, Z = NULL, weights = "numeric", return_var = FALSE, ...)
|
W |
A list of length 'k' containing matrices of error-prone proxy measurements of the covariate. Matrices should all be n (observations) x p (dimension of covariates). |
Z |
A matrix containing all error-free covariates for use in estimation. Matrix should be n (observations) x q (dimension). Use NULL if no such covariates exist. Defaults to NULL. |
weights |
Either a string from 'numeric', 'optimal', 'equal' (only required up to the point of unique identification) or a vector containing 'k' numbers, summing to one, which serve as the convex combination of weights. Defaults to 'numeric'. |
return_var |
A boolean represent whether the correction function and weights should be returned (TRUE) or only the imputed values. Defaults to FALSE. |
Either a matrix of imputed values of size n x p (if return_var is FALSE), or a list which contains elements $X.hat (the aforementioned imputed matrix), $fitRC (a function which can be used to make the same correction), and $weights (the weights used in the correction).
1 | generalizedRC(W, weights="equal")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.