I guess I should also mention the the "atom specifier" can just be "sel" to get whatever is currently selected.

--Eric

On Nov 17, 2014, at 4:45 PM, Eric Pettersen <pett@cgl.ucsf.edu> wrote:

On Nov 17, 2014, at 4:26 PM, Boris Steipe <boris.steipe@utoronto.ca> wrote:

For example I would like to perform some simple calculations on the coordinates of a set of selected atoms, and I see many functions that take a "sel" argument, but I can't seem to find documentation on exactly what that argument is expected to contain, or the function that would return such a selection list (is it even a list) of objects.

If we are talking about the the 'sel' argument given to many of the functions in Midas/__init__.py, that argument is usually "polymorphic", and can be any one of these:

  -- an atom specifier (e.g. "#1@ca")
  -- a list/tuple of Atoms/Residues/Molecules (homogeneous list/tuple though)
  -- a set of Atoms/Residues/Molecules (also homogenous, and unlike the list/tuple the set has to be at the right "level" for the function called [e.g. Atoms for distance])
  -- a Selection/OSLSelection (which Tom mentioned)

--Eric

                        Eric Pettersen
                        UCSF Computer Graphics Lab
                        http://www.cgl.ucsf.edu


_______________________________________________
Chimera-dev mailing list
Chimera-dev@cgl.ucsf.edu
http://plato.cgl.ucsf.edu/mailman/listinfo/chimera-dev