View source: R/plot.cellNetCoDa.R
| plot.cellNetCoDa | R Documentation |
Diagnostic plots for a cellNetCoDa object.
which = 1 (default) draws the estimated network with the parts as
nodes on a circular layout (node size proportional to degree).
which = 2 draws the cellwise contamination heatmap of the detector
flags (parts on the x-axis, observations on the y-axis).
which = 3 draws the StARS instability path used for penalty
selection (raw and monotonised instability over the penalty grid, with the
selection threshold and the chosen penalty marked).
## S3 method for class 'cellNetCoDa'
plot(x, y, ..., which = 1)
x |
object of class |
y |
not used |
... |
further arguments passed to |
which |
integer; |
Called for its side effect (a plot). Returns NULL
invisibly.
Matthias Templ
cellNetCoDa, print.cellNetCoDa,
summary.cellNetCoDa
if (requireNamespace("glmnet", quietly = TRUE)) {
data(expenditures)
set.seed(1)
net <- cellNetCoDa(expenditures, method = "mb",
lambda_grid = c(0.4, 0.2, 0.1, 0.05), B = 10, k = 2)
plot(net) # network graph
plot(net, which = 2) # contamination heatmap
plot(net, which = 3) # StARS instability path
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.