Skip to contents

Markdown tables

Usage

markdownTables(object, ...)

# S4 method for FgseaList
markdownTables(object, collection, n = 10L, headerLevel = 3L)

Arguments

object

Object.

collection

character(1). Gene set collection name. Typically refers to h (hallmark), c1-c7 collections from MSigDb. Can obtain using collectionNames() on FgseaList object.

n

integer(1). Number of significant processes to include. Bidirectional; will include n up- and down-regulated processes.

headerLevel

integer(1). Markdown header level.

...

Additional arguments.

Value

kable. Markdown tables.

Details

Top tables of significantly enriched pathways.

Supports looping across multiple DEG results, and adds a Markdown header for each contrast.

Note

Updated 2022-05-24.

Examples

data(fgsea)

## FgseaList ====
object <- fgsea
alphaThreshold(object) <- 0.9
collection <- collectionNames(object)[[1L]]
markdownTables(
    object = object,
    collection = collection
)
#> 
#> 
#> ### condition_B_vs_A
#> 
#> 
#> 
#> #### Upregulated
#> 
#> 
#> 
#> |pathway                          |  padj| log2err|   NES| size|
#> |:--------------------------------|-----:|-------:|-----:|----:|
#> |HALLMARK_KRAS_SIGNALING_UP       | 0.731|   0.352| 1.576|   21|
#> |HALLMARK_CHOLESTEROL_HOMEOSTASIS | 0.731|   0.322| 1.527|    6|
#> |HALLMARK_BILE_ACID_METABOLISM    | 0.731|   0.219| 1.417|    8|
#> |HALLMARK_ANGIOGENESIS            | 0.731|   0.234| 1.333|    2|
#> 
#> 
#> #### Downregulated
#> 
#> 
#> 
#> |pathway                    |  padj| log2err|    NES| size|
#> |:--------------------------|-----:|-------:|------:|----:|
#> |HALLMARK_KRAS_SIGNALING_DN | 0.731|   0.277| -1.545|   11|
#> |HALLMARK_MYC_TARGETS_V1    | 0.731|   0.219| -1.442|    8|
#> 
#> 
#> ### treatment_D_vs_C
#> 
#> 
#> 
#> #### Upregulated
#> 
#> 
#> 
#> |pathway                        |  padj| log2err|   NES| size|
#> |:------------------------------|-----:|-------:|-----:|----:|
#> |HALLMARK_MYC_TARGETS_V2        | 0.875|   0.106| 1.172|    4|
#> |HALLMARK_DNA_REPAIR            | 0.875|   0.119| 1.164|   14|
#> |HALLMARK_COMPLEMENT            | 0.875|   0.107| 1.110|   19|
#> |HALLMARK_MTORC1_SIGNALING      | 0.875|   0.106| 1.105|   19|
#> |HALLMARK_FATTY_ACID_METABOLISM | 0.875|   0.097| 1.077|   11|
#> |HALLMARK_P53_PATHWAY           | 0.875|   0.096| 1.061|   10|
#> |HALLMARK_UV_RESPONSE_DN        | 0.875|   0.093| 1.033|   13|
#> |HALLMARK_ALLOGRAFT_REJECTION   | 0.875|   0.095| 1.026|   16|
#> |HALLMARK_ANGIOGENESIS          | 0.875|   0.082| 1.015|    2|
#> |HALLMARK_KRAS_SIGNALING_UP     | 0.875|   0.090| 1.010|   21|
#> 
#> 
#> #### Downregulated
#> 
#> 
#> 
#> |pathway                                    |  padj| log2err|    NES| size|
#> |:------------------------------------------|-----:|-------:|------:|----:|
#> |HALLMARK_ESTROGEN_RESPONSE_EARLY           | 0.875|   0.140| -1.278|   17|
#> |HALLMARK_G2M_CHECKPOINT                    | 0.875|   0.126| -1.235|   16|
#> |HALLMARK_MYOGENESIS                        | 0.875|   0.126| -1.230|   11|
#> |HALLMARK_KRAS_SIGNALING_DN                 | 0.875|   0.116| -1.187|   11|
#> |HALLMARK_PROTEIN_SECRETION                 | 0.875|   0.105| -1.128|   11|
#> |HALLMARK_UV_RESPONSE_UP                    | 0.875|   0.093| -1.090|    8|
#> |HALLMARK_EPITHELIAL_MESENCHYMAL_TRANSITION | 0.875|   0.082| -1.008|   18|
#> |HALLMARK_SPERMATOGENESIS                   | 0.875|   0.079| -0.997|    9|
#> |HALLMARK_E2F_TARGETS                       | 0.875|   0.082| -0.996|   13|
#> |HALLMARK_APOPTOSIS                         | 0.875|   0.078| -0.981|   16|