from chimerax.atomic import all_structures
structures = all_structures(session)
Another way to get the structures is
from chimerax.atomic import Structure
structures = session.models.list(type = Structure)
More info about the Python functions in ChimeraX is in the programmer's manual
for instance the all_structures() function is under the atomic module. But that has hundreds of functions so it can certainly be hard to find
Tom
Dear ChimeraX Users,
I'm learning how to use the Python API and I found the set of ChimeraX recipes and am trying to use the code featured on the "Find Residues From Specified Residue Numbers" page. I've run into the following issue: NameError: name 'structure' is not defined.
I'm not sure what I should be using as an input for the "structure.residues" argument so I have not changed that input. What "structure" should I be specifying? Any help would be greatly appreciated.
Shosholoza,
Jonathan Myers
_______________________________________________ChimeraX-users mailing listChimeraX-users@cgl.ucsf.eduManage subscription:https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users