That's a bug in the new drawing code with molecules that have no extent in
either the X or Y directions. Here's the github item:
https://github.com/rdkit/rdkit/issues/1271
I'm surprised that the non-SVG version is working for you.

On Wed, Jan 18, 2017 at 11:19 PM, Curt Fischer <cu...@stanford.edu> wrote:

> Hi all,
>
> I'm not sure if this topic has come up before, but SVG rendering in
> Jupyter notebooks seems to make small molecules like methanol and water
> completely invisible.  The same molecules render successfully for me using
> non-SVG renderers.
>
> Can others reproduce this behavior?  Are there any easy-ish fixes for this?
>
> Curt
>
>
> *# import rdkit components*
> *from rdkit import Chem*
> *from rdkit.Chem import Draw*
> *from rdkit.Chem.Draw import IPythonConsole*
>
> *# two very small molecules*
> *methanol = Chem.MolFromSmiles('CO')*
> *water = Chem.MolFromSmiles('O')*
>
> *# SVG rendering seems to make small molecules like water and methanol
> completely invisible*
> *IPythonConsole.ipython_useSVG=True*
> *Draw.MolsToGridImage([water, methanol])*
>
> *# With SVG off the molecules are visible*
> *IPythonConsole.ipython_useSVG=False*
> *Draw.MolsToGridImage([water, methanol])*
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> _______________________________________________
> Rdkit-discuss mailing list
> Rdkit-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to