get_sequence
Retrieve the amino-acid sequence of a loaded PyMOL structure in FASTA format. See how sequence positions correspond to residue numbers and identify chain breaks.
Instructions
Returns the amino-acid sequence of a loaded structure, in FASTA.
Also reports how the sequence positions line up with the residue numbers in the file, and where the chain is broken. Both matter: PDB numbering rarely starts at 1, so "residue 50" in a paper and position 50 in the sequence are usually different residues — and unmodelled loops leave gaps in the structure that the sequence alone does not reveal.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chain | No | Chain to extract. Omit for every chain in the object. | |
| obj_name | Yes | PyMOL object (e.g. "1hsg"). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |