Sequence

This module handles individual sequences.

class Sequence(*args)[source]

Handle individual sequences of an MSA object

Depending on input arguments, instances may point to an MSA object or store its own data.

copy()[source]

Returns a copy of the instance that owns its sequence data.

getArray()[source]
getIndex()[source]

Returns sequence index or None.

getLabel(full=False)[source]

Returns label of the sequence.

getMSA()[source]

Returns MSA instance or None.

getResnums(gaps=False, report_match=False)[source]

Returns list of residue numbers associated with non-gapped seq. When gaps is True, return a list containing the residue numbers with gaps appearing as None.

Residue numbers are inferred from the full label if possible. When the label does not contain residue number information, a range of numbers starting from 1 is returned.

numGaps()[source]

Returns number of gap characters.

numResidues()[source]

Returns the number of alphabet characters.