phastCons(msa, mod, rho=0.3, target.coverage=0.05, expected.length=10,
transitions=NULL, estimate.rho=FALSE,
estimate.expected.length=FALSE, estimate.transitions=FALSE,
estimate.trees=FALSE, viterbi=TRUE, gc=NULL, nrates=NULL,
ref.idx=1, quiet=FALSE)msa representing the multiple
alignment to be scored.tm, or a list
containing two tm objects. If two objects are given, they
represent the conserved and non-conserved phylogenetic models. If
one is given, then this represents the non-conserved modelTRUE, Estimate the parameter
rho (as described above), using maximum likelihood. Estimated value is reported
in return list. This use is discouraged (see note below).TRUE, estimate the
expected length of conserved elements by maximum likelihood, and use the
target.coverage parameter for initialization. Setting this parameter to TRUE
is discouraged (see note below).TRUE, estimate the transition
rates between conserved and non-conserved states by maximum likelihood. The parameter
transitions is then used for initialization. This argument is ignored if
{estimate.expected.length==TRUTRUE, estimate free
parameters of tree models for conserved and non-conserved state. Setting this
argument to TRUE is discouraged (see note below).TRUE, produce discrete elements
using the Viterbi algorithm.TRUE, suppress printing of progress information.feat which describes conserved elements
detected by the Viterbi algorithm.require("rphast")
exampleArchive <- system.file("extdata", "examples.zip", package="rphast")
files <- c("ENr334.fa", "rev.mod")
unzip(exampleArchive, files)
mod <- read.tm("rev.mod")
msa <- read.msa("ENr334.fa")
rv <- phastCons(msa, mod)
names(rv)
rv2 <- phastCons(msa, mod, estimate.trees=TRUE)
names(rv2)
rv2$tree.models
unlink(files)Run the code above in your browser using DataLab