schrodinger.protein.seqres module¶
Functions for getting and setting SEQRES data on a structure.
- schrodinger.protein.seqres.get_seqres(st)¶
Read in all SEQRES data from the structure.
- Parameters
st (schrodinger.structure.Structure) – The structure to read SEQRES data from
- Returns
A dictionary of {chain name: list of residue names} (ordered identically to the SEQRES data in the
Structure
) or None if there’s no SEQRES information present in the structure. Note that the lists of residue names uses a OneIndexedList since the i_pdb_seqres_index residue property values assume a starting index of one.- Return type
dict(str, OneIndexedList[str]) or NoneType NOTE: Residue names in output lists will have whitespace stripped.
- schrodinger.protein.seqres.set_seqres(st, seqres)¶
Add SEQRES data to a structure. Any SEQRES data that was previously present in the structure will be overwritten.
- Parameters
st (schrodinger.structure.Structure) – The structure to add SEQRES data to.
seqres (dict(str, list[str]) or None) – A dictionary of {chain name: list of residue names}. May be None or an empty dictionary to clear SEQRES data. Each residue name must be either 3-characters or 4-characters long.
- schrodinger.protein.seqres.has_seqres(st)¶
Determine if a structure contains SEQRES data.
- Parameters
st (schrodinger.structure.Structure) – The structure to read SEQRES data from.
- Returns
Whether the structure contains SEQRES data.
- Return type
bool