plotAMR {ramr} | R Documentation

## Plot aberrantly methylated regions

### Description

'plotAMR' uses 'ggplot2' to visualize aberrantly methylated regions (AMRs) at particular genomic locations.

### Usage

    plotAMR(
      data.ranges,
      data.samples = NULL,
      amr.ranges,
      highlight = NULL,
      title = NULL,
      window = 300
    )

### Arguments

`data.ranges` | A 'GRanges' object with genomic locations and corresponding beta values included as metadata.
`data.samples` | A character vector with sample names (a subset of metadata column names) to be included in the plot. If 'NULL' (the default), then all samples (metadata columns) are included.
`amr.ranges` | An output of 'getAMR' - a 'GRanges' object that contain aberrantly methylated regions (AMRs).
`highlight` | An optional list of samples to highlight. If NULL (the default), will contain sample IDs from the 'sample' metadata column of 'amr.ranges' object.
`title` | An optional title for the plot. If NULL (the default), plot title is set to a genomic location of particular AMR.
`window` | An optional integer constant to expand genomic ranges of the 'amr.ranges' object (the default: 300).

### Details

For every non-overlapping genomic location from 'amr.ranges' object, 'plotAMR' plots and outputs a line graph of methylation beta values taken from 'data.ranges' for all samples from 'data.samples'. Samples bearing significantly different methylation profiles ('sample' column of 'amr.ranges' object) are highlighted.

### Value

The output is a list of 'ggplot' objects.

### See Also

`getAMR` for identification of AMRs, `getUniverse` for info on enrichment analysis, `simulateAMR` and `simulateData` for the generation of simulated test data sets, and 'ramr' vignettes for the description of usage and sample data.

### Examples

      data(ramr)
      plotAMR(ramr.data, ramr.samples, ramr.tp.unique[1])
      library(gridExtra)
      do.call("grid.arrange",
              c(plotAMR(ramr.data, ramr.samples, ramr.tp.nonunique), ncol=2))

[Package ramr version 1.2.0 Index]