visualizeRegion {sesame} | R Documentation

## Visualize Region

### Description

The function takes a genomic coordinate (chromosome, start and end) and a beta value matrix (probes on the row and samples on the column). It plots the beta values as a heatmap for all probes falling into the genomic region. If 'draw=TRUE' the function returns the plotted grid graphics object. Otherwise, the selected beta value matrix is returned. 'cluster.samples=TRUE/FALSE' controls whether hierarchical clustering is applied to the subset beta value matrix.

### Usage

    visualizeRegion(
      chrm,
      plt.beg,
      plt.end,
      betas,
      platform = c("EPIC", "HM450", "MM285"),
      refversion = c("hg38", "hg19", "mm10"),
      sample.name.fontsize = 10,
      heat.height = NULL,
      draw = TRUE,
      show.sampleNames = TRUE,
      show.samples.n = NULL,
      show.probeNames = TRUE,
      cluster.samples = FALSE,
      nprobes.max = 1000,
      na.rm = FALSE,
      dmin = 0,
      dmax = 1
    )

### Arguments

`chrm` | chromosome
`plt.beg` | begin of the region
`plt.end` | end of the region
`betas` | beta value matrix (row: probes, column: samples)
`platform` | EPIC, HM450, or MM285
`refversion` | hg38, hg19, or mm10
`sample.name.fontsize` | sample name font size
`heat.height` | heatmap height (auto inferred based on rows)
`draw` | draw figure or return betas
`show.sampleNames` | whether to show sample names
`show.samples.n` | number of samples to show (default: all)
`show.probeNames` | whether to show probe names
`cluster.samples` | whether to cluster samples
`nprobes.max` | maximum number of probes to plot
`na.rm` | remove probes with all NA.
`dmin` | data min
`dmax` | data max

### Value

graphics or a matrix containing the captured beta values

### Examples

    betas <- sesameDataGet('HM450.76.TCGA.matched')$betas
    visualizeRegion('chr20', 44648623, 44652152, betas, 'HM450')

[Package sesame version 1.12.9 Index]