align-utils {Biostrings}R Documentation

Utility functions related to sequence alignment

Description

A variety of different functions used to deal with sequence alignments.

Usage

  consmat(x, freq=TRUE)

Arguments

x A character vector, or an instance of either the BStringView, or the XStringAlign classes.
freq If TRUE then letter frequencies (per position) are reported, otherwise counts.

Details

consmat computes a consensus matrix for a set of equal-length strings assumed to be aligned.

See Also

XStringViews-class, XStringAlign

Examples

  file <- system.file("extdata", "someORF.fa", package="Biostrings")
  orf <- read.DNAStringSet(file, "fasta")

  ## To illustrate, the following example assumes the ORF data
  ## to be aligned for the first 10 positions (patently false):
  orf10 <- DNAStringSet(orf, end=10)
  consmat(orf10)

  ## For the character matrix containing the "exploded" representation
  ## of the views, do:
  as.matrix(orf10, mode="character")

[Package Biostrings version 2.8.18 Index]