compareBoxplots: Create a comparison plot of boxplots for bootstrapped AUC...

View source: R/bootstrap.R

compareBoxplotsR Documentation

Create a comparison plot of boxplots for bootstrapped AUC values.

Description

Present the results of AUC bootstrapping for a collection of scored signatures via boxplots.

Usage

compareBoxplots(
  SE_scored,
  annotationColName,
  signatureColNames,
  num.boot = 100,
  name = "Boxplot Comparison of Signature AUCs",
  pb.show = TRUE,
  abline.col = "red",
  fill.col = "gray79",
  outline.col = "black",
  rotateLabels = FALSE,
  violinPlot = FALSE
)

Arguments

SE_scored

a SummarizedExperiment object with genes as the row features and signature scores in the colData. There should also be a column of annotation data. Required.

annotationColName

a character string giving the column name in colData that contains the annotation data. Required.

signatureColNames

a vector of column names in the colData that contain the signature score data. Required.

num.boot

an integer indicating the number of times to bootstrap the data.

name

a character string giving the overall title for the plot. The default is "Boxplot Comparison of Signature AUCs".

pb.show

logical for whether to show a progress bar while running code. Default is TRUE.

abline.col

the color to be used for the dotted line at AUC = 0.5 (the chance line). The default is "red".

fill.col

the color to be used to fill the boxplots. The default is "white".

outline.col

the color to be used for the boxplot outlines. The default is "black".

rotateLabels

If TRUE, rotate labels. Default is FALSE.

violinPlot

logical. Setting violinPlot = TRUE creates violin plots in place of boxplots. The mean and +/- 1 standard deviation are added to the violin plot interior for each signature. The default is FALSE.

Value

A plot with side-by-side boxplots of bootstrapped AUC values for each specified signature.

Examples

# Run signature profiling
 choose_sigs <- TBsignatures[c("Zak_RISK_16", "Zhao_NANO_6")]
 prof_indian <- runTBsigProfiler(TB_indian[seq_len(25), ],
                                 useAssay = "logcounts",
                                 algorithm = "ssGSEA",
                                 signatures = choose_sigs,
                                 parallel.sz = 1)
 # Create boxplots
 compareBoxplots(prof_indian, annotationColName = "label",
                 signatureColNames = names(choose_sigs), rotateLabels = TRUE)


compbiomed/TBSignatureProfiler documentation built on Oct. 29, 2024, 6:07 a.m.