Re: [Rdkit-devel] fmcs in RDKit
Open-Source Cheminformatics and Machine Learning
Brought to you by:
glandrum
|
From: Andrew D. <da...@da...> - 2012-09-25 20:42:12
|
I made the last of the code changes. The public API now uses RDKit-style
mixedCase parameters instead of PEP 8-style underscore_names.
On Sep 25, 2012, at 4:44 AM, Greg Landrum wrote:
> Is there a python documentation generator that can process that and do
> something sensible with it? If so, I'm fine with it. If not, then
> maybe the @type bits can be combined into the @param somehow (yes, it
> would just be text then).
That was the theory. I've looked it over and greatly improved the
documentation by removing that autodoc section and using prose, like:
"""Find the maximum common substructure of a set of molecules
In the simplest case, pass in a list of molecules and get back
an MCSResult object which describes the MCS:
>>> from rdkit import Chem
>>> mols = [Chem.MolFromSmiles("C#CCP"), Chem.MolFromSmiles("C=CCO")]
>>> from rdkit.Chem import MCS
>>> MCS.FindMCS(mols)
MCSResult(numAtoms=2, numBonds=1, smarts='[#6]-[#6]', completed=1)
The SMARTS '[#6]-[#6]' matches the largest common substructure of
the input structures. It has 2 atoms and 1 bond. If there is no
MCS which is at least `minNumAtoms` in size then the result will set
numAtoms and numBonds to -1 and set smarts to None.
...
> The API docs are automatically generated. It would be nice to have a
> brief section for the GettingStarted document
> ($RDBASE/Docs/Book/GettingStartedInPython.rst), but I am willing to
> write that if you don't have time.
I've copied the doctoring, with slight modifications, into the Getting
Started document. One of the modifications was to show an example of
using three molecules, since the docstring only shows pairwise examples.
I don't like the document duplication. I'm not going to worry much
about it though.
Feel free to change as you wish.
Andrew
da...@da...
|