[Rdkit-discuss] FrameToGridImage Legend

2017-04-14 Thread François-Régis Chalaoux
Hi, I would like to save a legend for each molecule of the grid with 2 infos (Notebook and IC50) but my code below does not work : img = PandasTools.FrameToGridImage(frame, column='ROMol', molsPerRow=10,subImgSize=(200,200), legends=[str(x) for x in frame[['Notebook','IC50']]] ) Any idea ?

Re: [Rdkit-discuss] FrameToGridImage Legend

2017-04-14 Thread François-Régis Chalaoux
My solution is : foo = frame.assign(legend= frame['Notebook'] + ' / ' + frame['IC50']) print([str(x) for x in foo.columns]) img = PandasTools.FrameToGridImage(titi, column='ROMol', molsPerRow=10,subImgSize=(200,200),\ legends=[str(x) for x in titi['legend']] )