readPHMM {aphid}R Documentation

Import profile hidden Markov models into R.

Description

The readPHMM function parses a HMMER3 text file into R and creates an object of class "PHMM".

Usage

readPHMM(file = "", ...)

Arguments

file

the name of the file from which to read the model.

...

further arguments to be passed to "scan".

Details

This function scans a HMMER3/f text file and creates an object of class "PHMM" in R. Note that unlike HMMER, the aphid package does not currently support position-specific background emission probabilities, and so only a single vector the same length as the reside alphabet is included as an element of the returned object. Also the function currently only parses the first profile HMM encountered in the text file, with subsequent models ignored.

Value

an object of class "PHMM".

Author(s)

Shaun Wilkinson

References

Finn RD, Clements J & Eddy SR (2011) HMMER web server: interactive sequence similarity searching. Nucleic Acids Research. 39, W29-W37. http://hmmer.org/.

HMMER: biosequence analysis using profile hidden Markov models. http://www.hmmer.org.

See Also

writePHMM for writing PHMM objects in HMMER3 text format.

Examples

  ## Derive a profile hidden Markov model from the small globin alignment
  data(globins)
  x <- derivePHMM(globins, residues = "AMINO", seqweights = NULL)
  fl <- tempfile()
  writePHMM(x, file = fl)
  readPHMM(fl)

[Package aphid version 1.3.3 Index]