plotLongFeature: Plot longitudinal features

Description Usage Arguments Value Author(s) Examples

View source: R/longitudinal_functions.R

Description

This function plots the reads of a particular feature over different time points.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
plotLongFeature(
  aggdat,
  feature,
  x_var,
  id_var = "SAMPLE_ID",
  plotTitle = NULL,
  ylab = "Reads",
  log = FALSE,
  showLines = TRUE,
  fixedHeight = NULL,
  x_levels = NULL,
  pwidth = 650
)

Arguments

aggdat

aggregated MRExperiment

feature

Feature to plot.

x_var

Phenotype to show along on X-axis.

id_var

phenotype used to connect data points. Default is "SAMPLE_ID"

plotTitle

Plot title. Default shows no title.

ylab

Y-axis label. Default is "Reads"

log

Log2 transform data. Default is FALSE.

showLines

add lines between the points

fixedHeight

sets a specific plot height (differential analysis)

x_levels

restrict to specific levels of x_var (differential analysis)

pwidth

overall plot width; default is 650

Value

plotly object holding long feature plot

Author(s)

Janina Reeder, Mo Huang

Examples

1
2
3
4
data("mouseData", package = "metagenomeSeq")
aggdat <- aggFeatures(mouseData, level = "genus")
plotLongFeature(aggdat, feature = "Prevotella", x_var = "diet", 
                id_var = "mouseID")

microbiomeExplorer documentation built on Nov. 8, 2020, 8:16 p.m.