Thanks Greg!
BondCompare.CompareAny is exactly what I needed

Best,
Marta

2016-07-06 7:47 GMT+02:00 Greg Landrum <greg.land...@gmail.com>:
> Marta,
>
> On Tue, Jul 5, 2016 at 11:14 AM, Marta Stępniewska-Dziubińska
> <mart...@ibb.waw.pl> wrote:
>>
>>
>> To be honest, I expected it to fail :)
>
>
> I'm glad to hear that!
>
>> I want to find structures with a defined topology, but allow for
>> different bond types. My first idea was to use SMARTS with ~ bonds,
>> and it works fine with GetSubstructMatch.
>
>
> Assuming that I'm understanding the idea correctly, your best bet is
> probably to use BondCompare.CompareAny. Here's a simple demonstration:
>
> In [15]: m1 = Chem.MolFromSmiles('C=CC')
> In [16]: m2 = Chem.MolFromSmiles('CCC')
> In [17]: FindMCS((m1,m2),
> bondCompare=rdFMCS.BondCompare.CompareAny).smartsString
> Out[17]: '[#6]=,-[#6]-[#6]'
>
>
>> I don't really need MCS, I just used it to check different patterns.
>> But I expected that FindMCS will throw an exception, rather than
>> produce SMARTS it cannot parse.
>
>
> Agreed. Here's the bug report: https://github.com/rdkit/rdkit/issues/968
> If you keep an eye on that (or subscribe to it) in github you'll see when
> it's fixed.
>
> Best,
> -greg

------------------------------------------------------------------------------
Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape
_______________________________________________
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to