pwm.heatmap: Draw a heatmap of a position-weight matrix (from 'make.pwm'

Description Usage Arguments Value Author(s) Examples

View source: R/viRome_functions.R View source: R/pwm.heatmap.R

Description

Draw a heatmap of a position-weight matrix (from make.pwm. Uses the image function

Usage

1
pwm.heatmap(pwm = NULL, col.fun = colorRampPalette(c("black", "red"), space = "rgb"), mar = c(3, 2, 1, 1), cex.axis = 0.8)

Arguments

pwm

Output from make.pwm. Rows are bases/nucleotides, columns are position and values are proportions

col.fun

A colour function such as rainbow. Defaults to colorRampPalette(c("black", "red"), space = "rgb")

mar

The margins for the plot. See par. A numerical vector of the form c(bottom, left, top, right) which gives the number of lines of margin to be specified on the four sides of the plot.

cex.axis

A scaling factor for the axes labels

Value

An image is plotted to the current device

Author(s)

Mick Watson <mick.watson@roslin.ed.ac.uk>

Examples

1
2
3
4
5
6
## Not run: infile <- system.file("examples/SRR389184_vs_SINV_sorted.bam", package="viRome")
 ## Not run: bam <- read.bam(bamfile=infile, chr="SINV", minlen=1, maxlen=11703, removeN=TRUE)
 ## Not run: bamc <- clip.bam(bam)
 ## Not run: pwm1 <- make.pwm(bamc, minlen=25, maxlen=29, strand="neg")
## Not run: pwm.heatmap(pwm1)
## Not run: pwm.heatmap(pwm1, col.fun=colorRampPalette(c("green","red"), space="rgb"))

mw55309/viRome_legacy documentation built on Dec. 21, 2021, 11:05 p.m.