load_aligned_seqs#
- load_aligned_seqs(filename: str | Path, format: str | None = None, array_align: bool = True, moltype: str | None = None, label_to_name: Callable[[str], str] | None = None, parser_kw: dict | None = None, info: dict | None = None, new_type: bool = False, **kw) Alignment #
loads aligned sequences from file
- Parameters:
- filenamestr
path to sequence file
- formatstr
sequence file format, if not specified tries to guess from the path suffix
- moltype
the moltype, eg DNA, PROTEIN, ‘dna’, ‘protein’
- array_alignbool
if True, returns ArrayAlignment, otherwise an annotatable Alignment
- label_to_name
function for converting original name into another name.
- parser_kwdict
optional arguments for the parser
- new_type
if True, the returned Alignment will be of the new type, (cogent3.core.new_alignment.Alignment). Support for the old style will be removed as of 2025.6.
- kw
passed to make_aligned_seqs
- Returns:
ArrayAlignment
orAlignment
instance