huge.glassoM(x, lambda = NULL, lambda.min.ratio = NULL, nlambda = NULL, cov.glasso = FALSE, verbose = TRUE)
n
by d
data matrix representing n
observations in d
dimensions.lambda = NULL
and have the program compute its own lambda
sequence based on nlambda
and lambda.min.rat
10
.lambda
, as a fraction of the uppperbound (MAX
) of the regularization/thresholding parameter which makes all estimates equal to 0
. The program can automatically generate lambda
as acov.glasso = TRUE
, the outpu will inlcude a path of estimated covariance matrices. Since the estimated covariance matrices are generally not sparse, please use it with care, or it may take much memory under high-dimensional setting. The deverbose = FALSE
, tracing information printing is disabled. The default value is TRUE
."glassoM"
is returned:k
by k
adjacency matrices of estimated graphs (in sparse matrix representation) as a solution path (graph path) corresponding to lambda
.d
by d
estimated precision matrices (in sparse matrix representation) as an alternative graph path (numerical path) corresponding to lambda
.d
by d
estimated covariance matrices corresponding to lambda
. ONLY applicable when cov.glasso = TRUE
nlambda
dimensional vector containing the likelihood scores along the graph path (wi
).nlambda
dimensional vector containing the number of nonzero coefficients along the graph path (wi
).huge.glassoM()
is actually a modified version of Friedman's glassopath() in a memory efficient manner. Since in most case we are usually only interested in sparse results, instead of using a regular array, we store the graph path in a list with each element corresponding to an estimated precision matrix or graph in sparse matrix representation. This slightly change can help to reduce the memory usage in the high dimensional case. We also follow Dr. Friedman's warm start procedure and make this function computational efficient and stable.huge
, glasso
, glassopath
and huge-package
.#generate data
L = huge.generator(n = 200, d = 100, graph = "hub")
#graph graph path estimation
out1 = huge.glassoM(L$data)
summary(out1)
plot(out1)
#Graph graph path estimation with specified nlambda and lambda.min.ratio
out3 = huge(L, method = "GLASSO", nlambda = 8, lambda.min.ratio = 0.2)
summary(out3)
plot(out3)
Run the code above in your browser using DataLab