Hi Noel,

Thanks for response. The paper didn't really mention the R/S configuration
but their supplemental had it. Here is the first two rows of their
supplemental dataset.

CID SMILES MW N O XLogP HBD HBA RotB tPSA nStereo R S
Lipitor 60823 CC(C)C1=C(C(=C(N1CC[C@H](C[C@H
](CC(=O)O)O)O)C2=CC=C(C=C2)F)C3=CC=CC=C3)C(=O)NC4=CC=CC=C4 558,64 2 5 5,7 4
7 12 112,0 2 2 0
Nexium 4594 CC1=CN=C(C(=C1OC)C)CS(=O)C2=NC3=C(N2)C=C(C=C3)OC 345,42 3 3 0,6
1 6 5 77,1 1 1 0


For the stereocenters I wrote:

    nStereo=0
    for atom in mol:
        if atom.OBAtom.IsChiral() and atom.OBAtom.GetAtomicNum() == 6:
            nStereo+=1

Would that work just like OBStereoFacade? I'm not familiar with using that
class.

I'm not sure how to conduct a floodfill search of a molecule. Are there
examples that you can point me to? I simply wrote this but I lack the
knowledge to carry on:

mol =
pybel.readstring('smi','CC(=O)SC1CC2=CC(=O)CCC2(C3C1C4CCC5(C4(CC3)C)CCC(=O)O5)C')
for a in mol:
    if a.OBAtom.IsInRing():
        print(f'{a.idx}, {a.atomicnum}, {a.cidx}')

Can you provide further assistance? Thanks.


Best regards,


Spencer


Vào Th 2, 13 thg 5, 2019 vào lúc 09:45 Noel O'Boyle <baoille...@gmail.com>
đã viết:

> Hi Spencer,
>
> To count the number of ring systems, simply find a ring atom that you have
> not yet visited (OBAtom.IsInRing()) and floodfill through all of the
> adjacent ring atoms via bonds that are in a ring. That's ring system 1.
> Repeat to find additional ring systems.
>
> In the reference you point to, they don't count the number of R
> stereocenters and S stereocenters. They use "chiralCenterCount()", defined
> as " Calculates the number of tetrahedral stereogenic centers" (
> https://forum.chemaxon.com/ftopic2417.html). If you use the
> OBStereoFacade, you should be able to count up the stereo centers.
> Hopefully this number is the same as you are expecting.
>
> Regards,
>    Noel
>
>
>
> On Mon, 13 May 2019 at 02:03, Spencer Trinh <trinh.kc...@gmail.com> wrote:
>
>> Hi Openbabel developers,
>>
>> I am trying to reproduce the data from this paper:
>> https://www.ncbi.nlm.nih.gov/pubmed/25618349
>>
>> They listed 20 chemical descriptors used for a pca analysis. I am having
>> trouble figuring out how they calculated the ring system count. Is there a
>> way to count the number of ring systems as opposed to standard rings? For
>> example, spiro rings are considered one instead of two, etc. I simply know
>> how to get ring count through: mol.OBMol.GetSSSR(). Also, I don't know how
>> to count the number of R stereocenters and S stereocenters. Is this
>> possible with Openbabel? I would assume so since it can do a lot of things.
>> Thank you.
>>
>>
>>
>> Best regards,
>>
>>
>> Spencer
>> _______________________________________________
>> OpenBabel-discuss mailing list
>> OpenBabel-discuss@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
>>
>
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to