Learn R Programming

bio3d (version 2.1-2)

plot.fasta: Plot a Multiple Sequence Alignment

Description

Produces a schematic representation of a multiple sequence alignment.

Usage

## S3 method for class 'fasta':
plot(x, plot.labels = TRUE,
                     plot.bars = TRUE,
                     plot.lines = FALSE,
                     plot.axis = TRUE,
                     seq.index = NULL,
                     color.conserved = FALSE,
                     cutoff=0.5, 
                     col=NULL,
                     bars.scale=2,
                     row.spacing=0.5,
                     aln.col="grey50",
                     cex.text=1, add=FALSE, ...)

Arguments

x
multiple sequence alignement of class fasta as obtained from seqaln.
plot.labels
logical, if TRUE labels will be printed next to the sequence bar.
plot.bars
logical, if TRUE an additional bar representing sequence conservation will be plotted.
plot.lines
logical, if TRUE sequence conservation will be represented with a plot.
plot.axis
logical, if TRUE x-axis will be plotted.
seq.index
printed tick labels will correspond to the sequence of the provided index.
color.conserved
logical, if TRUE conserved residues will be colored according to clustal coloring scheme.
cutoff
conservation cutoff value below which alignment columns are not colored.
col
character vector with color codes for the conservation bars. By default, heat.colors will be used.
bars.scale
scaling factor for the height of the conservation bar when plot.bars=TRUE.
row.spacing
space between the sequence bars.
aln.col
color of the alignment bars.
cex.text
scaling factor for the labels.
add
logical, if TRUE plot.new() will not be called.
...
additional arguments not paseed anywhere.

Value

  • Called for its effect.

Details

plot.fasta is a utility function for producting a schematic representation of a multiple sequence alignment.

References

Grant, B.J. et al. (2006) Bioinformatics 22, 2695--2696.

See Also

seqaln, read.fasta, entropy, aln2html.

Examples

Run this code
# Read alignment
aln<-read.fasta(system.file("examples/kif1a.fa",package="bio3d"))

## alignment plot
plot(aln)

infile <- "http://pfam.sanger.ac.uk/family/PF00071/alignment/seed/format?format=fasta"
aln <- read.fasta( infile )
plot(aln)

Run the code above in your browser using DataLab