toPWM {PWMEnrich} | R Documentation

## Convert motifs into PWMs

### Description

Convert motifs into PWMs

### Usage

    toPWM(motifs, ids = names(motifs), targets = names(motifs),
      seq.count = 50, prior = c(A = 0.25, C = 0.25, G = 0.25, T = 0.25), ...)

### Arguments

`motifs` | a list of motifs either as position probability matrices (PPM) or frequency matirces (PFMs)
`ids` | the set of IDs for the motifs (defaults to names of the 'motifs' list)
`targets` | the set of target TF names for the motifs (defaults to names of the 'motifs' list)
`seq.count` | provides a vector of sequence counts for probability matrices (PPMs)
`prior` | frequencies of the four letters in the genome. Default is uniform background
`...` | other parameters to PWMUnscaled

### Examples

    if(require("PWMEnrich.Dmelanogaster.background")){
       data(MotifDb.Dmel.PFM)

       toPWM(MotifDb.Dmel.PFM) # convert to PWM with uniform background

       prior = getBackgroundFrequencies("dm3", quick=TRUE) # get background for drosophila (quick mode on a reduced dataset)
       toPWM(MotifDb.Dmel.PFM, prior=prior) # convert with genomic background
    }

[Package PWMEnrich version 4.22.0 Index]