This routine fits glasso using a robust covariance matrix
robglasso(
data,
covest = cov,
rho = 0.1,
CV = FALSE,
k = 10,
grids = 15,
evaluation = negLLrobOmega,
...
)raw data, should be a matrix or a data.frame, row as sample
a *function* or name of a function (string) that takes a matrix to estimate covariance
a scalar or vector of tuning parameters to be chosen, if CV=FALSE, should be a scalar, if CV=TRUE scalar input will be override and tuning parameter will be chosen based on CV
bool, whether doing cross validation for tuning parameter, if set to TRUE and rho is a scalar, the candidate will be chosen automatically by log spacing between 0.01 max covariance and max covariance with number of grids
fold for cross validation if applicable
number of candidate tuning parameters in cross validation
a *function* or name of a function (string) that takes only two arguments, the estimated *covariance* and the test *covariace*, when NULL, we use negative log likelihood on test sets
extra argument sent to glasso::glasso
a glasso return (see ?glasso::glasso), most important one is $X the estimated sparse precision,with an extra entry of tuning parameter lambda
# NOT RUN {
robglasso(matrix(rnorm(100),20,5))
# }
Run the code above in your browser using DataLab