Closed rbf22 closed 3 years ago
The following works for me:
for atom_i in model.atoms():
for atom_j in atom_i.nearby_atoms(6.):
print(atom_j.chain, atom_j.het.name, atom_j.het.id.split(".")[1])
The residue number is a bit convoluted because residues currently just have an ID of the form A.123
- I think I should make the number a separate property in future.
Is there a way to get the residue type, i.e. THR, SER etc?
atom.het.name
returns the residue type.
it would be great if while iterating over nearby atoms it was possible to access the chain and residues for these atoms. Is there a way to do this?
for example: