Skip to contents

This function collects the results of bootstrapping and t-tests for a scored gene expression dataset and presents them using a JavaScript table with an R interface, or as a data.frame.

Usage

tableAUC(
  SE_scored,
  annotationColName,
  signatureColNames,
  num.boot = 100,
  pb.show = TRUE,
  output = "DataTable"
)

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

integer. The number of times to bootstrap the data. The default is 100.

pb.show

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

output

a character string indicating the table output format. Possible values are DataTable and data.frame. The default is DataTable.

Value

A JavaScript table with an R interface using the DT package.

Examples

# Run signature profiling
 choose_sigs <- TBsignatures[c(1, 2)]
 prof_indian <- runTBsigProfiler(TB_indian, useAssay = "logcounts",
                                 algorithm = "ssGSEA",
                                 signatures = choose_sigs,
                                 parallel.sz = 1,
                                 update_genes = FALSE)
#> Running ssGSEA
#> Warning: 1 genes with constant values throughout the samples.
#> [1] "Calculating ranks..."
#> [1] "Calculating absolute values from ranks..."
#> [1] "Normalizing..."
 # Create table
 tableAUC(SE_scored = prof_indian, annotationColName = "label",
          signatureColNames = names(choose_sigs))
#> 
  |                                                                            
  |                                                                      |   0%
  |                                                                            
  |===================================                                   |  50%
  |                                                                            
  |======================================================================| 100%
# Create data.frame object h <- tableAUC(SE_scored = prof_indian, annotationColName = "label", signatureColNames = names(choose_sigs), output = "data.frame", num.boot = 5) #> | | | 0% | |=================================== | 50% | |======================================================================| 100% head(h) #> Signature P.value neg10xLog.P.value. LowerAUC AUC UpperAUC #> 1 Anderson_42 2e-04 87.4837 0.7503 0.8105 0.9394 #> 2 Anderson_OD_51 0e+00 259.5843 0.9833 0.9832 0.9915