Package schrodinger :: Module structure :: Class _Chain
[hide private]
[frames] | no frames]

Class _Chain

_AtomCollection --+
                  |
                 _Chain

A class used to return chain information when iterating over chains in a Structure object.

Important methods include extractStructure and getAtomList. The atom attribute can be used to iterate over all atoms in the molecule, and the number of atoms can be determined via len(molecule.atom).

The residue iterator allows for iteration over residues of the chain, returning _Residue instances.

Instance Methods [hide private]
 
__init__(self, st, chain, atoms)
Initialize the Chain object.
 
_getChainResidueIterator(self)
 
_getChainName(self)
 
_setChainName(self, newname)
 
_getChainBF(self)
 
__str__(self)
Return a string representation - consistent with other structure.py code.
 
applyStyle(self, atoms=ATOM_BALLNSTICK, bonds=BOND_BALLNSTICK)
Applies the given display styles to the atoms and bonds of the chain.

Inherited from _AtomCollection: __len__, atom, extractStructure, getAtomList

Class Variables [hide private]
  residue = property(_getChainResidueIterator, doc= "Returns res...
  name = property(_getChainName, _setChainName, doc= "Chain name")
  temperature_factor = property(_getChainBF, doc= "Chain B (temp...
Method Details [hide private]

__init__(self, st, chain, atoms)
(Constructor)

 

Initialize the Chain object.

Overrides: _AtomCollection.__init__

applyStyle(self, atoms=ATOM_BALLNSTICK, bonds=BOND_BALLNSTICK)

 

Applies the given display styles to the atoms and bonds of the chain.

Parameters:
  • atoms (int) - display style for atoms given by structure module constants ATOM_NOSTYLE, ATOM_CIRCLE, ATOM_CPK, ATOM_BALLNSTICK. Default is ATOM_BALLNSTICK.
  • atoms (int) - display style for bonds given by structure module constants BOND_NOSTYLE, BOND_WIRE, BOND_TUBE, BOND_BALLNSTICK. Default is BOND_BALLNSTICK.
  • bonds (int)

Class Variable Details [hide private]

residue

Value:
property(_getChainResidueIterator, doc= "Returns residue iterator for \
all residues in the chain")

temperature_factor

Value:
property(_getChainBF, doc= "Chain B (temperature) factor")