Table of Contents

Module: __init__ AddH/__init__.py

Add hydrogens to structures

Imported modules   
import chimera
from chimera import Element, Element_bondLength, idatm
from chimera.bondGeom import single
from chimera.idatm import geometry, substituents
import operator
import string
Functions   
determineNamingSchemas
gatherUnknowns
hbondAddHydrogens
newHydrogen
simpleAddHydrogens
  determineNamingSchemas 
determineNamingSchemas ( molecule,  typeInfo )

Determine for each residue, method for naming hydrogens

The two possible schemas are: replace -- put H in place of element name prepend -- put H in front of entire atom name

In both cases, a number will be appended if more than one hydrogen is to be added.

Replace is the preferred scheme and is used when the heavy atoms have been given reasonably distinctive names. Prepend is used mostly in small molecules where the atoms have names such as C1, C2, C3, N1, N2, etc. and replace would not work.

  gatherUnknowns 
gatherUnknowns ( models,  prevUnknowns=[] )

Find atoms whose hydrogen-adding geometries are unknown

  hbondAddHydrogens 
hbondAddHydrogens ( models,  unknownsInfo={} )

Add hydrogens to given models, trying to preserve H-bonding

Otherwise similar to simpleAddHydrogens(); see comments there

  newHydrogen 
newHydrogen (
        parentAtom,
        Hnum,
        totalHydrogens,
        namingSchema,
        )

  simpleAddHydrogens 
simpleAddHydrogens ( models,  unknownsInfo={} )

Add hydrogens to given models using simple geometric criteria

Geometric info for atoms whose IDATM types don't themselves provide sufficient information can be passed via the unknownsInfo dictionary. The keys are atoms and the values are dictionaries specifying the geometry and number of substituents (not only hydrogens) for the atom.

This routine adds hydrogens immediately even if some atoms have unknown geometries. To allow the user to intervene to specify geometries, use the initiateAddHyd function of the unknownsGUI module of this package.


Table of Contents

This document was automatically generated on Wed Mar 26 19:01:59 2003 by HappyDoc version 2.1