Package Bio :: Package Fasta :: Module FastaAlign :: Class FastaAlignment
[hide private]
[frames] | no frames]

Class FastaAlignment

source code

Align.Generic.Alignment --+
                          |
                         FastaAlignment

Work with the Fasta Alignment format.

The fasta alignment format is basically the same as the regular ol' Fasta format we know and love, except the sequences have gaps (represented by -'s).

Instance Methods [hide private]
 
__init__(self, alphabet=Gapped(IUPACAmbiguousDNA(), '-'))
Initialize a new Alignment object.
source code
 
__str__(self)
Print out a fasta version of the alignment info.
source code

Inherited from Align.Generic.Alignment: __format__, __getitem__, __iter__, __repr__, add_sequence, format, get_alignment_length, get_all_seqs, get_column, get_seq_by_num

Inherited from Align.Generic.Alignment (private): _str_line

Method Details [hide private]

__init__(self, alphabet=Gapped(IUPACAmbiguousDNA(), '-'))
(Constructor)

source code 

Initialize a new Alignment object.

Arguments: o alphabet - The alphabet to use for the sequence objects that are created. This alphabet must be a gapped type.

e.g. >>> from Bio.Alphabet import IUPAC, Gapped >>> align = Alignment(Gapped(IUPAC.unambiguous_dna, "-")) >>> align.add_sequence("Alpha", "ACTGCTAGCTAG") >>> align.add_sequence("Beta", "ACT-CTAGCTAG") >>> align.add_sequence("Gamma", "ACTGCTAGDTAG") >>> print align Gapped(IUPACUnambiguousDNA(), '-') alignment with 3 rows and 12 columns ACTGCTAGCTAG Alpha ACT-CTAGCTAG Beta ACTGCTAGDTAG Gamma

Overrides: Align.Generic.Alignment.__init__
(inherited documentation)

__str__(self)
(Informal representation operator)

source code 

Print out a fasta version of the alignment info.

Overrides: Align.Generic.Alignment.__str__