Learn R Programming

misha (version 5.11.23)

gseq.read_homer: Read motifs from a HOMER motif format file

Description

Parses a HOMER .motif format file and returns a named list of position probability matrices (PPM). Each matrix has rows corresponding to motif positions and columns A, C, G, T. The returned matrices are directly usable with gseq.pwm.

Usage

gseq.read_homer(file)

Value

A named list of numeric matrices. Each matrix has columns

A, C, G, T and one row per motif position. List names are derived from the consensus sequence. Each matrix carries the following attributes:

name

Motif name / description from the header

consensus

Consensus sequence from the header

log_odds_threshold

Detection threshold (numeric)

log_p_value

Log p-value (numeric)

w

Motif width (integer)

source

"homer"

Arguments

file

character(1) path to a HOMER motif file (.motif).

See Also

Other motif functions: gseq.read_jaspar(), gseq.read_meme()

Examples

Run this code
if (FALSE) {
motifs <- gseq.read_homer("known_motifs.motif")
names(motifs)
m <- motifs[[1]]
head(m)
attr(m, "consensus")
}

Run the code above in your browser using DataLab