probOverlapHit {motifcounter} | R Documentation |
This function computes a set of self-overlapping probabilites for a motif and background model.
probOverlapHit(pfm, bg, singlestranded = FALSE)
pfm |
An R matrix that represents a position frequency matrix |
bg |
A Background object |
singlestranded |
Boolean that indicates whether a single strand or both strands shall be scanned for motif hits. Default: singlestranded = FALSE. |
The 'gamma's are determined based on two-dimensional score distributions (similar as described in Pape et al. 2008), however, they are computed based on an order-d background model. On the other hand, the 'beta's represent overlapping hit probabilities that were corrected for intermediate hits.
An Overlap object
# Load sequences seqfile = system.file("extdata", "seq.fasta", package = "motifcounter") seqs = Biostrings::readDNAStringSet(seqfile) # Load background bg = readBackground(seqs, 1) # Load motif motiffile = system.file("extdata", "x31.tab", package = "motifcounter") motif = t(as.matrix(read.table(motiffile))) # Compute overlapping hit probabilities for scanning both DNA strands op = motifcounter:::probOverlapHit(motif, bg, singlestranded = FALSE) # Compute overlapping hit probabilities for scanning a single DNA strand op = motifcounter:::probOverlapHit(motif, bg, singlestranded = TRUE)