This is from lipinski.cpp:
if (strict == NonStrict) {
std::string pattern = "[!$(*#*)&!D1]-&!@[!$(*#*)&!D1]";
pattern_flyweight m(pattern);
return m.get().countMatches(mol);
}
else if (strict==Strict) {
std::string strict_pattern =
"[!$(*#*)&!D1&!$(C(F)(F)F)&!$(C(Cl)(Cl)Cl)&!$(C(Br)(Br)Br)&!$(C([CH3])("
"[CH3])[CH3])&!$([CD3](=[N,O,S])-!@[#7,O,S!D1])&!$([#7,O,S!D1]-!@[CD3]="
"[N,O,S])&!$([CD3](=[N+])-!@[#7!D1])&!$([#7!D1]-!@[CD3]=[N+])]-!@[!$(*#"
"*)&!D1&!$(C(F)(F)F)&!$(C(Cl)(Cl)Cl)&!$(C(Br)(Br)Br)&!$(C([CH3])([CH3])"
"[CH3])]";
pattern_flyweight m(strict_pattern);
return m.get().countMatches(mol);
} else {
I suspect that it's taking the "Strict" brach, where the SMARTS pattern is
more complex and actually has a rule that excludes tert-butyl (the
"&!$(C([CH3])([CH3])[CH3])]" at the end).
Ivan
On Tue, Oct 15, 2019 at 1:06 PM Geoffrey Hutchison <
[email protected]> wrote:
> I'm using a script in RDKit to grab a bunch of descriptors for QSAR / ML.
> I have a particular question about the # of rotatable bonds:
>
> Consider:
>
> from rdkit import Chem
> from rdkit.Chem import Descriptors
> example = Chem.MolFromSmiles("CN(C(=O)OC(C)(C)C)C(=S)NC(=O)OC(C)(C)C")
> Descriptors.NumRotatableBonds(example)
> 0
>
> example2 = Chem.MolFromSmiles("CC(C)(C)CCC(C)(C)C")
> Descriptors.NumRotatableBonds(example2)
> 1
>
>
> Can someone explain why a terminal butyl isn't a rotatable bond? Based on
> mailing list questions, I thought NumRotatableBonds was supposed to return
> matches for the SMARTS "[!$(*#*)&!D1]-&!@[!$(*#*)&!D1]" (e.g. what's
> defined in the Lipinski code).
>
> Thanks,
> -Geoff
>
>
>
> _______________________________________________
> Rdkit-discuss mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
_______________________________________________
Rdkit-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss