pulsar {pulsar} | R Documentation |
pulsar: serial or parallel mode
Description
Run pulsar using StARS' edge stability (or other criteria) to select an undirected graphical model over a lambda path.
Usage
pulsar(
data,
fun = huge::huge,
fargs = list(),
criterion = c("stars"),
thresh = 0.1,
subsample.ratio = NULL,
rep.num = 20,
seed = NULL,
lb.stars = FALSE,
ub.stars = FALSE,
ncores = 1,
refit = TRUE
)
Arguments
data |
A |
fun |
pass in a function that returns a list representing |
fargs |
arguments to argument |
criterion |
A character vector of selection statistics. Multiple criteria can be supplied. Only StARS can be used to automatically select an optimal index for the lambda path. See details for additional statistics. |
thresh |
threshold (referred to as scalar |
subsample.ratio |
determine the size of the subsamples (referred to as |
rep.num |
number of random subsamples |
seed |
A numeric seed to force predictable subsampling. Default is NULL. Use for testing purposes only. |
lb.stars |
Should the lower bound be computed after the first |
ub.stars |
Should the upper bound be computed after the first |
ncores |
number of cores to use for subsampling. See |
refit |
Boolean flag to refit on the full dataset after pulsar is run. (see also |
Details
The options for criterion
statistics are:
stars (Stability approach to regularization selection)
gcd (Graphet correlation distance, requires the orca package) see
gcvec
diss (Node-node dissimilarity) see
graph.diss
estrada (estrada class) see
estrada.class
nc (natural connectivity) see
natural.connectivity
sufficiency (Tandon & Ravikumar's sufficiency statistic)
Value
an S3 object of class pulsar
with a named member for each stability metric run. Within each of these are:
summary: the summary statistic over
rep.num
graphs at each value of lambdacriterion: the stability criterion used
merge: the raw statistic over the
rep.num
graphs, prior to summarizationopt.ind: index (along the path) of optimal lambda selected by the criterion at the desired threshold. Will return
if no optimum is found or
NULL
if selection for the criterion is not implemented.
If stars
is included as a criterion then additional arguments include
lb.index: the lambda index of the lower bound at
samples if
lb.stars
flag is set to TRUEub.index: the lambda index of the upper bound at
samples if
ub.stars
flag is set to TRUE
call: the original function call
References
Müller, C. L., Bonneau, R., & Kurtz, Z. (2016). Generalized Stability Approach for Regularized Graphical Models. arXiv. https://arxiv.org/abs/1605.07072
Liu, H., Roeder, K., & Wasserman, L. (2010). Stability approach to regularization selection (stars) for high dimensional graphical models. Proceedings of the Twenty-Third Annual Conference on Neural Information Processing Systems (NIPS).
Zhao, T., Liu, H., Roeder, K., Lafferty, J., & Wasserman, L. (2012). The huge Package for High-dimensional Undirected Graph Estimation in R. The Journal of Machine Learning Research, 13, 1059–1062.
See Also
Examples
## Not run:
## Generate the data with huge:
library(huge)
p <- 40 ; n <- 1200
dat <- huge.generator(n, p, "hub", verbose=FALSE, v=.1, u=.3)
lams <- getLamPath(getMaxCov(dat$data), .01, len=20)
## Run pulsar with huge
hugeargs <- list(lambda=lams, verbose=FALSE)
out.p <- pulsar(dat$data, fun=huge::huge, fargs=hugeargs,
rep.num=20, criterion='stars')
## Run pulsar in bounded stars mode and include gcd metric:
out.b <- pulsar(dat$data, fun=huge::huge, fargs=hugeargs,
rep.num=20, criterion=c('stars', 'gcd'),
lb.stars=TRUE, ub.stars=TRUE)
plot(out.b)
## End(Not run)