load_seq#

load_seq(filename: PathLike, annotation_path: PathLike | None = None, format: str | None = None, moltype: str | None = None, label_to_name: Callable | None = None, parser_kw: dict | None = None, info: dict | None = None, **kw) Sequence#

loads unaligned sequences from file

Parameters:
filenamestr

path to sequence file

formatstr

sequence file format, if not specified tries to guess from the path suffix

moltypestr

the moltype, eg DNA, PROTEIN, ‘dna’, ‘protein’

label_to_namecallable

function for converting original name into another name.

parser_kwdict

optional arguments for the parser

infodict

a dict from which to make an info object

**kw

other keyword arguments passed to SequenceCollection

Returns:
Sequence

Notes

Returns one sequence from a file. Use load_aligned_seqs or load_unaligned_seqs to get a collection.