Package schrodinger :: Package trajectory :: Module atomselection :: Class _AtomSelection
[hide private]
[frames] | no frames]

Class _AtomSelection

A general class for ASL expression support.

Marked as private because it will probably be moved or removed.

Instance Methods [hide private]
 
__init__(self, st, asl_expr='all')
 
updateSelection(self)
A method to allow updating the selection for a modified structure.
 
_setSelection(self)
Set the current selection atoms.
 
asl_expr(self)
atom selection expression
 
_setAslExpr(self, asl_expr)
Set the ASL expression and update the selection.
 
isDynamic(self)
 
selected_indices(self)
 
selected_bitset(self)
 
__iter__(self)
Iterate over selected atoms, returning _StructureAtom instances.
 
__getitem__(self, n)
Get item 'n' (as a _StructureAtom instance) from the selected atoms.
 
__len__(self)
Return the number of atoms in the selection.
Method Details [hide private]

updateSelection(self)

 

A method to allow updating the selection for a modified structure. This is useful for dynamic expressions (i.e. ones that depend on structure coordinates).

asl_expr(self)

 

atom selection expression

Decorators:
  • @property

selected_indices(self)

 
Decorators:
  • @property

selected_bitset(self)

 
Decorators:
  • @property

__getitem__(self, n)
(Indexing operator)

 

Get item 'n' (as a _StructureAtom instance) from the selected atoms. Index starts at 1 and refers to the position in the selected atoms list.