From: Christoph S. <c.s...@un...> - 2004-06-07 12:52:13
|
Hi Rickard, My impression is that one is in trouble when lacking *both* hydrogen counts *and* bond orders. We currently have no way of detecting bond orders from 3D coordinates. Can anyone on the list comment on my first statement?` With respect to the general strategy you are talking about: If we assume that we have no problem lacking both H's and bond orders, then the strategy would be to first rebond, then use StructureDiagramGenerator to generate 2D coordinates for the molecule without H's, then use HydrogenAdder to add the missing H's and then use HydrogenPlace to make the coordinates for the H's. Again, we are missing the bond orders here :-) Currently, CDK can either addHydrogensToSatisfyValency() (given all the bond orders in the molecule) *or* addjustBondOrdersToSatisfyValency() given the correct H-Counts (not sure about the method name of the last method). Cheers, Chris Rickard Nordstrom wrote: > Hi, > > I have just got started using CDK. One of my initial tasks > > that I would like to perform using CDK is adding all > > hydrogens to several small molecules. The molecules are read > > as pdb files with no connect information. I would like my > > software using CDK to detect the valency in rings (not tried > > that yet) and then add hydrogens. When I tried adding > > hydrogens using the below code and the > > HydrogenPlacer.placeHydrogens2D(mol, bondlength) method I > > get an error due to the fact that my small molecules lack 2D > > coordinates. I then used AtomTools.add3DCoordinates1(mol) > > instead which indeed added hydrogens but with some of them > > in funny positions. Is there a preferred way to reliably add > > hydrogens using CDK? I also wonder if there is some methods > > that can detect the valency in rings (that can detect single > > and double bonds) from the 3D coordinates only? > > > > RebondTool rebondTool = new RebondTool(maxCovalentRadius, > > minBondDistance, bondTolerance); > > rebondTool.rebond(mol); > > double bondLength = GeometryTools.getBondLengthAverage(mol); > > HydrogenAdder hAdder = new HydrogenAdder(); > > hAdder.addExplicitHydrogensToSatisfyValency(mol); > > //AtomTools.add3DCoordinates1(mol); > > //HydrogenPlacer.placeHydrogens2D(mol, bondLength); > > > > Sincerely > > Rickard Nordstrom > > > -- Dr. rer. nat. habil. Christoph Steinbeck (c.s...@un...) Groupleader Junior Research Group for Applied Bioinformatics Cologne University BioInformatics Center (http://www.cubic.uni-koeln.de) Zülpicher Str. 47, 50674 Cologne Tel: +49(0)221-470-7426 Fax: +49 (0) 221-470-7786 What is man but that lofty spirit - that sense of enterprise. ... Kirk, "I, Mudd," stardate 4513.3.. |