makePWM: Constructing a pwm object

Description Usage Arguments Value Author(s) Examples

View source: R/pwm.R

Description

This function constructs an object of class pwm from a matrix. It checks that the matrix has correct dimensions and that columns add up to 1.0.

Usage

1
makePWM(pwm, alphabet = "DNA")

Arguments

pwm

matrix. Numerical matrix representing the position weight matrix.

alphabet

character. The alphabet making up the sequence. Currently, only 'DNA' and 'RNA' is supported.

Value

An object of class pwm.

Author(s)

Oliver Bembom

Examples

1
2
3
mFile <- system.file("extdata/pwm1", package = "seqLogo")
m <- read.table(mFile)
pwm <- makePWM(m)

Example output

Loading required package: grid

seqLogo documentation built on Nov. 8, 2020, 8:20 p.m.