plotTerms {slalom} | R Documentation

## Plot relevance for all terms

### Description

Plot relevance for all terms

### Usage

    plotTerms(object, terms = NULL, order_terms = TRUE, mad_filter = 0.2,
      annotated = TRUE, unannotated_dense = TRUE, unannotated_sparse = FALSE)

### Arguments

`object` | an object of class `Rcpp_SlalomModel`
`terms` | integer or character vector, providing either indices for desired terms (if an integer) or the term names (if character); default is `NULL`, in which case all terms are plotted.
`order_terms` | logical(1), should factors be ordered by relevance ( `TRUE`, default), or in the order the come
`mad_filter` | numeric(1), filter factors by this mean absolute deviation to exclude outliers. For large datasets this can be set close to 0; default is `0.2`.
`annotated` | logical(1), should annotated factors be plotted? Default is `TRUE`
`unannotated_dense` | logical(1), should dense unannotated factors be plotted? Default is `TRUE`
`unannotated_sparse` | logical(1), should sparse unannotated factors be plotted? Default is `TRUE`

### Value

a ggplot plot object

### Examples

    gmtfile <- system.file("extdata", "reactome_subset.gmt", package = "slalom")
    genesets <- GSEABase::getGmt(gmtfile)
    data("mesc")
    model <- newSlalomModel(mesc, genesets, n_hidden = 5, min_genes = 10)
    model <- initSlalom(model)
    model <- trainSlalom(model, nIterations = 10)
    plotTerms(model)

[Package slalom version 1.2.0 Index]