Hi all,

Is there a function computing the sum of the absolute value of each
charge? (eg one COO- and one NH2+ would raise a total of 2).

But that's not my question :)
In one of my script function, I ionize the current molecule with
mol.OBMol.AddHydrogens(False, True, 7.4)
It works well, but it modifies the molecule in the "main" too.
So, I would like to go back to the non-ionic form (eg COOH and -NH-), but
mol.OBMol.DeleteHydrogens()
keeps eg. NH2+

I didn't see a funtion able to do that, is there one?

If I do a copy of the molecule before ionization, modification of the
first modifies the second...

If I do:
import copy
and e.g.
molCopy = copy.copy(mol)
the modification is still propagating to both (and same, I suppose...)
objects (molCopy and mol).

copy.deepcopy(mol) raises an error.

Any hint for doing a separate copy?

Thanks,
Regards,
Pascal

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
OpenBabel-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to