View source: R/plot.bootstrap.r
plot.bootstrap | R Documentation |
Plot the results of a fitted rgcca_bootstrap object. Each block variable is shown along with its associated bootstrap confidence interval and stars reflecting the p-value of assigning a strictly positive or negative weight to this block variable.
## S3 method for class 'bootstrap' plot( x, block = seq_along(x$rgcca$call$blocks), comp = 1, type = "weights", empirical = TRUE, n_mark = 30, display_order = TRUE, show_stars = TRUE, title = NULL, cex = 1, cex_sub = 12 * cex, cex_main = 14 * cex, cex_lab = 12 * cex, cex_point = 3 * cex, colors = NULL, adj.method = "fdr", ... )
x |
A fitted rgcca_bootstrap object
(see |
block |
A numeric corresponding to the block(s) to plot. |
comp |
A numeric vector indicating the component(s) to consider. |
type |
Character string indicating the bootstrapped object to plot: block-weight vectors ("weights", default) or block-loading vectors ("loadings"). |
empirical |
A logical value indicating if the bootstrap confidence intervals and p-values are derived from the empirical distribution. (defaut: TRUE) |
n_mark |
An integer defining the maximum number of variables plotted. |
display_order |
A logical value for ordering the variables. If TRUE, variables are ordered from highest to lowest absolute value. If FALSE, the block order is used. Default is TRUE. |
show_stars |
A logical for showing significance levels. |
title |
A character string giving the title of the plot. |
cex |
A numeric defining the size of the objects in the plot. Default is one. |
cex_sub |
A numeric defining the font size of the subtitle. Default is 12 * cex. |
cex_main |
A numeric defining the font size of the title. Default is 14 * cex. |
cex_lab |
A numeric defining the font size of the labels. Default is 12 * cex. |
cex_point |
A numeric defining the font size of the points. Default is 3 * cex. |
colors |
Colors used in the plots. |
adj.method |
Character string indicating the method used to adjust for p-values. It must be a method handled by the p.adjust function. Default is "fdr". |
... |
Additional graphical parameters. |
A ggplot2 plot object.
data("Russett") blocks <- list( agriculture = Russett[, seq(3)], industry = Russett[, 4:5], politic = Russett[, 6:11] ) fit.rgcca <- rgcca(blocks, ncomp = 2, method = "rgcca", tau = 1) fit.boot <- rgcca_bootstrap(fit.rgcca, n_boot = 20, n_cores = 1) plot(fit.boot, type = "weight", block = 1, comp = 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.