File: matchProbePair.Rd

package info (click to toggle)
r-bioc-biostrings 2.42.1-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 14,652 kB
  • ctags: 721
  • sloc: ansic: 10,262; sh: 11; makefile: 2
file content (94 lines) | stat: -rw-r--r-- 2,926 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
\name{matchProbePair}

\alias{matchProbePair}
\alias{matchProbePair,DNAString-method}
\alias{matchProbePair,XStringViews-method}
\alias{matchProbePair,MaskedDNAString-method}


\title{Find "theoretical amplicons" mapped to a probe pair}

\description{
  In the context of a computer-simulated PCR experiment, one wants to find
  the amplicons mapped to a given primer pair.
  The \code{matchProbePair} function can be used for this: given a forward and a
  reverse probe (i.e. the chromosome-specific sequences of the forward and
  reverse primers used for the experiment) and a target sequence (generally a
  chromosome sequence), the \code{matchProbePair} function will return all
  the "theoretical amplicons" mapped to this probe pair.
}

\usage{
matchProbePair(Fprobe, Rprobe, subject, algorithm="auto", logfile=NULL, verbose=FALSE)
}

\arguments{
  \item{Fprobe}{
    The forward probe.
  }
  \item{Rprobe}{
    The reverse probe.
  }
  \item{subject}{
    A \link{DNAString} object (or an \link{XStringViews} object
    with a \link{DNAString} subject) containing the target sequence.
  }
  \item{algorithm}{
    One of the following: \code{"auto"}, \code{"naive-exact"},
    \code{"naive-inexact"}, \code{"boyer-moore"} or \code{"shift-or"}.
    See \code{\link{matchPattern}} for more information.
  }
  \item{logfile}{
    A file used for logging.
  }
  \item{verbose}{
    \code{TRUE} or \code{FALSE}.
  }
}

\details{
  The \code{matchProbePair} function does the following: (1) find all
  the "plus hits" i.e. the Fprobe and Rprobe matches on the "plus" strand,
  (2) find all the "minus hits" i.e. the Fprobe and Rprobe matches on the
  "minus" strand and (3) from the set of all (plus\_hit, minus\_hit) pairs,
  extract and return the subset of "reduced matches" i.e. the (plus\_hit, minus\_hit)
  pairs such that (a) plus\_hit <= minus\_hit and (b) there are no hits (plus
  or minus) between plus\_hit and minus\_hit.
  This set of "reduced matches" is the set of "theoretical amplicons".
}

\value{
  An \link{XStringViews} object containing the set of "theoretical amplicons".
}

\author{H. Pagès}

\seealso{
  \code{\link{matchPattern}},
  \code{\link{matchLRPatterns}},
  \code{\link{findPalindromes}},
  \code{\link{reverseComplement}},
  \link{XStringViews-class}
}

\examples{
library(BSgenome.Dmelanogaster.UCSC.dm3)
subject <- Dmelanogaster$chr3R

## With 20-nucleotide forward and reverse probes:
Fprobe <- "AGCTCCGAGTTCCTGCAATA"
Rprobe <- "CGTTGTTCACAAATATGCGG"
matchProbePair(Fprobe, Rprobe, subject) # 1 "theoretical amplicon"

## With shorter forward and reverse probes, the risk of having multiple
## "theoretical amplicons" increases:
Fprobe <- "AGCTCCGAGTTCC"
Rprobe <- "CGTTGTTCACAA"
matchProbePair(Fprobe, Rprobe, subject) # 2 "theoretical amplicons"
Fprobe <- "AGCTCCGAGTT"
Rprobe <- "CGTTGTTCACA"
matchProbePair(Fprobe, Rprobe, subject) # 9 "theoretical amplicons"
}

\keyword{methods}