prob.seq {RJaCGH} | R Documentation |
This function computes posterior joint probabilities of alteration for arbitrary (contiguous) sets of probes. They are computed counting the times the particular sequence of alterations have ocurred in the Viterbi paths of every MCMC sample.
prob.seq(obj, from, to, filename, alteration = "Gain")
obj |
An object of class 'RJaCGH', 'RJaCGH.genome' or 'RJaCGH.Chrom' |
from |
Index of the starting probe to compute joint probability. |
to |
Index of the ending probe to compute joint probaility. |
filename |
name of the file with the Viterbi paths
(created with getSequence . |
alteration |
either 'Gain' or 'Loss'. |
Before using this function, a call to getSequence
must be made in order to create the Viterbi paths.
Note that the indexes for from
and to
are
absolute, not relative to the chromosome.
A joint probability of 'alteration' for the probes between 'from' and 'to'.
Oscar M. Rueda and Ramon Diaz Uriarte
Rueda OM, Diaz-Uriarte R. Flexible and Accurate Detection of Genomic Copy-Number Changes from aCGH. PLoS Comput Biol. 2007;3(6):e122
RJaCGH
, pREC_A
, link{\getSequence}
,
pREC_S
## Not run: y <- c(rnorm(100, 0, 1), rnorm(10, -3, 1), rnorm(20, 3, 1), rnorm(100,0, 1)) Pos <- sample(x=1:500, size=230, replace=TRUE) Pos <- cumsum(Pos) Chrom <- rep(1:23, rep(10, 23)) jp <- list(sigma.tau.mu=rep(0.5, 4), sigma.tau.sigma.2=rep(0.3, 4), sigma.tau.beta=rep(0.7, 4), tau.split.mu=0.5, tau.split.beta=0.5) fit.genome <- RJaCGH(y=y, Pos=Pos, Chrom=Chrom, model="genome", burnin=10, TOT=1000, k.max = 4, jump.parameters=jp) getSequence(fit.genome, 'sequence', 'Gain') prob.seq(fit.genome, 1, 4, 'sequence', 'Gain') ## End(Not run)