Browse code

Add Rd files for calculatePosteriorMean, genotypes, posteriorProbability, and predictionRegion

git-svn-id: file:///home/git/hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/crlmm@58631 bc3139a8-67e5-0310-9ffc-ced21a209358

Rob Scharp authored on 01/10/2011 04:46:59
Showing5 changed files

... ...
@@ -1,7 +1,7 @@
1 1
 Package: crlmm
2 2
 Type: Package
3 3
 Title: Genotype Calling (CRLMM) and Copy Number Analysis tool for Affymetrix SNP 5.0 and 6.0 and Illumina arrays.
4
-Version: 1.11.10
4
+Version: 1.11.11
5 5
 Date: 2010-12-10
6 6
 Author: Benilton S Carvalho <Benilton.Carvalho@cancer.org.uk>, Robert Scharpf <rscharpf@jhsph.edu>, Matt Ritchie <mritchie@wehi.edu.au>, Ingo Ruczinski <iruczins@jhsph.edu>, Rafael A Irizarry
7 7
 Maintainer: Benilton S Carvalho <Benilton.Carvalho@cancer.org.uk>, Robert Scharpf <rscharpf@jhsph.edu>, Matt Ritchie <mritchie@wehi.EDU.AU>
8 8
new file mode 100644
... ...
@@ -0,0 +1,56 @@
1
+\name{calculatePosteriorMean}
2
+\alias{calculatePosteriorMean}
3
+\alias{calculatePosteriorMean,CNSet-method}
4
+%- Also NEED an '\alias' for EACH other topic documented here.
5
+\title{Calculate the posterior mean of the integer copy numbers}
6
+\description{
7
+
8
+  Computes the posterior mean copy number from the bivariate normal
9
+  prediction regions.
10
+
11
+}
12
+
13
+\usage{
14
+calculatePosteriorMean(object, posteriorProb, copyNumber = 0:4, w, ...)
15
+}
16
+%- maybe also 'usage' for other objects documented here.
17
+\arguments{
18
+  \item{object}{
19
+    A \code{CNSet} object.
20
+}
21
+  \item{posteriorProb}{
22
+    The posterior probability for copy numbers 0-4.
23
+  }
24
+
25
+  \item{copyNumber}{
26
+    Integer vector.
27
+}
28
+\item{w}{
29
+  The prior probability for the copy numbers in \code{copyNumber}
30
+}
31
+  \item{\dots}{
32
+    Ignored
33
+}
34
+}
35
+\details{
36
+}
37
+\value{
38
+  An array  (features x samples x copy number)
39
+}
40
+
41
+\author{
42
+R. Scharpf
43
+}
44
+
45
+
46
+%% ~Make other sections like Warning with \section{Warning }{....} ~
47
+
48
+\seealso{
49
+  \code{\link{predictionRegion}}, \code{\link{posteriorProbability}}
50
+}
51
+\examples{
52
+}
53
+% Add one or more standard keywords, see file 'KEYWORDS' in the
54
+% R documentation directory.
55
+\keyword{array}
56
+\keyword{models}
0 57
new file mode 100644
... ...
@@ -0,0 +1,37 @@
1
+\name{genotypes}
2
+\alias{genotypes}
3
+%- Also NEED an '\alias' for EACH other topic documented here.
4
+\title{
5
+  The possible genotypes for an integer copy number.
6
+}
7
+\description{
8
+  The possible genotypes for an integer copy number (0-4).
9
+}
10
+\usage{
11
+genotypes(copyNumber)
12
+}
13
+%- maybe also 'usage' for other objects documented here.
14
+\arguments{
15
+  \item{copyNumber}{
16
+    Integer (0-4 allowed).
17
+}
18
+}
19
+\details{
20
+
21
+}
22
+\value{
23
+  Character vector.
24
+}
25
+
26
+\author{
27
+R. Scharpf
28
+}
29
+
30
+
31
+\examples{
32
+for(i in 0:4) print(genotypes(i))
33
+}
34
+% Add one or more standard keywords, see file 'KEYWORDS' in the
35
+% R documentation directory.
36
+\keyword{manip}
37
+x
0 38
new file mode 100644
... ...
@@ -0,0 +1,51 @@
1
+\name{posteriorProbability}
2
+\alias{posteriorProbability}
3
+\alias{posteriorProbability,CNSet-method}
4
+%- Also NEED an '\alias' for EACH other topic documented here.
5
+\title{Calculate the posterior probability for integer copy numbers.}
6
+
7
+\description{
8
+  Calculate the posterior probability for integer copy numbers using the
9
+  bivariate normal prediction regions.
10
+}
11
+
12
+\usage{
13
+posteriorProbability(object, predictRegion, copyNumber = 0:4)
14
+}
15
+%- maybe also 'usage' for other objects documented here.
16
+\arguments{
17
+  \item{object}{
18
+    A \code{CNSet} object.
19
+}
20
+  \item{predictRegion}{
21
+    A list containing the bivariate normal prediction region for each of
22
+    the possible genotypes.
23
+}
24
+  \item{copyNumber}{
25
+    Integer vector.
26
+}
27
+}
28
+\details{
29
+
30
+}
31
+\value{
32
+An array (features x samples x copy number)
33
+}
34
+
35
+\author{
36
+R. Scharpf
37
+}
38
+\note{
39
+  %Remark about nonpolymorphic probes
40
+}
41
+
42
+%% ~Make other sections like Warning with \section{Warning }{....} ~
43
+
44
+\seealso{
45
+  \code{\link{predictionRegion}}, \code{\link{genotypes}}, \code{\link{calculatePosteriorMean}}
46
+}
47
+\examples{
48
+}
49
+% Add one or more standard keywords, see file 'KEYWORDS' in the
50
+% R documentation directory.
51
+\keyword{array}
0 52
\ No newline at end of file
1 53
new file mode 100644
... ...
@@ -0,0 +1,66 @@
1
+\name{predictionRegion}
2
+\alias{predictionRegion}
3
+\alias{predictionRegion,CNSet,integer-method}
4
+\title{Prediction regions for integer copy number}
5
+\description{Bivariate normal prediction regions for integer copy
6
+  number.  Copy numbers 0-4 allowed.}
7
+\usage{
8
+predictionRegion(object, copyNumber)
9
+}
10
+%- maybe also 'usage' for other objects documented here.
11
+\arguments{
12
+  \item{object}{A \code{CNSet} object.}
13
+  \item{copyNumber}{Integer vector.  0-4 allowed.}
14
+}
15
+\details{
16
+
17
+  We fit a linear regression for each allele to the diallic genotype
18
+  cluster medians.  Denoting the background and slope by nu and phi,
19
+  respectively, the mean for the bivariate normal prediction region is
20
+  given by
21
+
22
+  mu_A = nu_A + CA * phi_A
23
+
24
+  and
25
+
26
+  mu_B nu_B + CB * phi_B
27
+
28
+  The variance and correlation of the normalized intensities is
29
+  estimated from the diallelic genotype clusters AA, AB, and BB on the
30
+  log-scale.  For copy number not equal to two, we assume that the
31
+  variance is approximately the same for copy number not equal to 2.
32
+
33
+}
34
+
35
+\value{
36
+
37
+  A list named by the genotype.  `NULL' refers to copy number zero, `A'
38
+  is a hemizygous deletion, etc. Each element is a list of the means
39
+  (mu) and covariance (cov) for each marker.  The covariance for each
40
+  marker is stored as a vector in the order variance A, correlation,
41
+  variance B. For nonpolymorphic markers, only the first mu and the
42
+  first variance are used.
43
+
44
+}
45
+
46
+
47
+\references{
48
+  Scharpf et al., 2011, Biostatistics.
49
+}
50
+\author{
51
+  R. Scharpf
52
+}
53
+
54
+%% ~Make other sections like Warning with \section{Warning }{....} ~
55
+
56
+\seealso{
57
+
58
+}
59
+\examples{
60
+data(sample.CNSet)
61
+pr <- predictionRegion(cnSet, copyNumber=0:4)
62
+}
63
+% Add one or more standard keywords, see file 'KEYWORDS' in the
64
+% R documentation directory.
65
+\keyword{ ~kwd1 }
66
+\keyword{ ~kwd2 }% __ONLY ONE__ keyword per line