get_alignment#

biotite.sequence.io.fasta.get_alignment(fasta_file, additional_gap_chars=('_',), seq_type=None)[source]#

Get an alignment from a FastaFile instance.

Parameters:
fasta_fileFastaFile

The FastaFile to be accessed.

additional_gap_charsstr, optional

The characters to be treated as gaps.

seq_typetype[Sequence], optional

The Sequence subclass contained in the file. If not set, the type is automatically inferred as ProteinSequence or NucleotideSequence. For large sequence data it is recommended to set this parameter.

Returns:
alignmentAlignment

The alignment from the FastaFile.