Python: module selectLogic
tools to perform logical operations on atom selections
NOTE: not tested! These routines need to be fixed.
Classes |
| |
- builtins.object
-
- BoolArray
class BoolArray(builtins.object) |
|
BoolArray(size, arr)
Array whose values are zero or one. The array's size is determined by
the size argument to the constructor. All members of the array are zero
except those corresponding to indices specified by the second argument to
the constructor.
Simple boolean operations can be performed on BoolArrays.
An array of the nonzero elements can be obtained using the simpleArray
method. |
|
Methods defined here:
- __and__(s, x)
- __init__(s, size, arr)
- Initialize self. See help(type(self)) for accurate signature.
- __neg__(s)
- __or__(s, x)
- Return self|value.
- simpleArray(s)
Data descriptors defined here:
- __dict__
dictionary for instance variables (if defined)
- __weakref__
list of weak references to the object (if defined)
| |
Functions |
| |
- select(str, strNS=None, size=None)
- perform logical operations on select arrays.
For instance, if
sel1 = select('name CA')
sel2 = select('name N')
then
selectLogic('sel1 or sel2')
returns the indices of all CA and N atoms.
|