cool_seq_tool.utils#
Provide a small set of general helper functions.
- cool_seq_tool.utils.get_inter_residue_pos(start_pos, end_pos, residue_mode)[source]#
Return equivalent inter-residue position.
Generally, we prefer to work with inter-residue coordinates where possible. Our rationale is detailed in an appendix to the VRS docs. This function is used internally to shift user-provided coordinates accordingly.
>>> from cool_seq_tool.utils import get_inter_residue_pos >>> from cool_seq_tool.schemas import ResidueMode >>> get_inter_residue_pos(10, ResidueMode.RESIDUE) ((9, 9), None)
- Parameters:
start_pos (
int
) – Start positionend_pos (
int
) – End positionresidue_mode (
ResidueMode
) – Residue mode for start_pos and end_pos
- Return type:
Tuple
[int
,int
]- Returns:
Inter-residue coordinates