This may have already been addressed in the next release, but I wanted to
be sure. It appears that Pandas was refactored in the 0.20.1 release in a
way that breaks PandasTools:
Python 3.6.1 |Continuum Analytics, Inc.| (default, May 11 2017, 13:25:24)
[MSC v.1900 64 bit (AMD64)] on win32
Type
Hi Steve,
Thanks for pointing this out.
Brian fixed this on master a while ago (
https://github.com/rdkit/rdkit/pull/1410) and we will have the fix in the
2017.03.2 patch release (coming, hopefully, next week).
Here's a quick demo that it actually works:
In [2]: pandas.__version__
Out[2]:
No. The main reason that the conda recipe includes pandas is for testing
the pandas extension. We could probably remove it from the run-time
dependency however and let the user install it in addition.
In any case, feel free to remove pandas from the conda installation.
Cheers,
Brian
On Tue
Hi,
I just upgraded rdkit from 2017.03.1 to 2017.03.2 using Conda. What I
have noticed is that pandas are now installed during the installation
of rdkit.
Does rdkit depend on pandas now? Is it safe to remove it? If it works
without pandas, maybe it makes sense to remove the dependency.
Kind
Hi Thomas,
I'm not sure how to configure conda so that a pip-installed version of
numpy and/or pandas is used, but you can use conda versions without MKL by
installing the nomkl package.
This conda command creates a functioning environment that does not have the
MKL installed:
conda crea
Dear all,
would it be possible to make RDKit package not depend on mkl (probably via
numpy, pandas) and that it accepts pre-installed numpy and pandas for example
from pip as sufficient?
The background to this is simple. Intel MKL cripples performance on any AMD
bases processor (4-5 times
I'm not sure how to configure conda so that a pip-installed version of numpy
and/or pandas is used, but you can use conda versions without MKL by installing
the nomkl package.
This conda command creates a functioning environment that does not have the MKL
installed:
conda create -n no_mkl
Dier Niko,
Thank you for your quick reply.
I tried to use pandas 0.18.0 and I work fine. ;-)
Best regards,
Takayuki
2016年6月2日(木) 3:13 Nikolas Fechner :
> Hi Takayuki,
> It seems that the respective piece of the pandas API got restructured for
> 0.18.1 and that the “format" mo
Hi Takayuki,
It seems that the respective piece of the pandas API got restructured for
0.18.1 and that the “format" module got moved from pandas.core to
pandas.formats:
Example change from the pandas github:
-from pandas.core import format as fmt
+from pandas.formats i
the core DataFrame class of pandas to disable the HTML escaping, which is enabled by default in pandas, so this methods affects ALL dataframes. Seeing HTML code in a dataframe is an indicator that something around this pandas patching was not done.The method is called inside
Hi,
Thanks for your response.
The problem is that I’d like to chunk Pandas dataframes to different
processors. And efficiently as possible, remove those rows which fail to be
converted into RDKit Mols. What I find however, is that the entire process
dies if the PandasTools fails to
Sorry I missed that you were on windows.
It looks like you can probably carefully construct an environment manually
using the '--no-deps' argument to "conda install"
I created and activated a python 3.7 environment on windows, installed
pandas and numpy from pip, and then
What I'm failing to understand here is what you want to do.
Do you want the rows with molecules that failed to parse to remain in the
DataFrame?
If not you can just remove them (there's probably a simpler way to do this,
but Pandas never fails to surprise me):
filtered_df = df[df['
Probably not the reason, but there was an older version of pandas, 0.24 IIRC,
that dinner render the molecules correctly.
Can you perform calculations on the mol objects?
On Mar 29, 2020, at 4:07 AM, Tim Dudgeon wrote:
I'm finding that if I create a pandas dataframe
Hi,
Pandas apply function will work too.
AddMoleculeColumnToFrame(DF, "Smiles") at first.
Default setting, rdkit mol object will be added "ROMol" column in your
dataframe.
https://www.rdkit.org/docs/source/rdkit.Chem.PandasTools.html
Then call apply function to apply a
Dear all,
We developed a new module ( rdkit.Chem.PandasTools.py ) that allows for using
RDKit molecule objects directly in pandas dataframes. Pandas
(http://pandas.pydata.org/) is a python library that offers table-like
datacontainers, which are incredibly useful for anything related to data
From: Taka Seri
Sent: 31 October 2019 10:15
To: Jan Halborg Jensen
Cc: Mike Mazanetz ; RDKit Discuss
Subject: Re: [Rdkit-discuss] calculating molecular properties on a Pandas
dataframe Molecule
Hi,
Pandas apply function will work too.
AddMoleculeColumnToFrame(DF, "Smiles
Dear all,
a tutorial ipython notebook for using the RDKit/Pandas integration is now
available on the wiki (<http://code.google.com/p/rdkit/wiki/Tutorials> - Using
Pandas in combination with RDKit).
There is also a new version of the PandasTools module in the rdkit trunk on
GitHub. This fix
- freetype
- eigen
- rdkit
- ipykernel
- pip:
- pandas
I suspect just installing from this yml won't work as some of these libs have
unlisted dependencies while for rdkit you want no deps. So below the exact
non-optimized order of commands used:
conda create -n rdkit_openblas python=3.7
Strange. It's just started working now.
I can't explain it.
On 30/03/2020 08:30, Markus Heller wrote:
Probably not the reason, but there was an older version of pandas,
0.24 IIRC, that dinner render the molecules correctly.
Can you perform calculations on the mol objects?
On Mon, Jun 17, 2013 at 4:08 PM, Michał Nowotka wrote:
> I'm trying to understand your advice? Should I check if I have pandas
> installed and uninstall it? Or installing pandas will help me with testing?
sorry, I was confusing. I could reproduce an error that occurs with
the current
Question to rdkit pandas users (pandaskitters?):
I managed to have the mol_send(m) object in a pandas frame:
[image: Inline images 1]
if I do this: data['mol'].map(str).map(Chem.Mol)
I get the mol in base64 PNG:
[image: Inline images 2]
How do I display the column as rendered images
Hi,
Is it possible to export from a Pandas data frame to Excel, inserting the
structures as images in the excel sheet?
Cheers
Chris
___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit
nce that’s done, you can address the rows where mol is ‘None’ …
From: Mike Mazanetz
Sent: Thursday, October 31, 2019 8:54 AM
To: 'Fiorella Ruggiu'
Cc: 'RDKit Discuss'
Subject: Re: [Rdkit-discuss] failed mols in converting SMILES to Pandas
dataframe Molecule
Hi Fio,
Than
Dear RDKitter,
on my new Windows laptop, I run into this issue:
"
import pandas as pd
import rdkit.Chem as Chem
from rdkit.Chem import PandasTools
"
=>
"
ValueErrorTraceback (most recent call
last)
in ()
1 import pandas as pd
2 im
Thanks Greg!
I find the pandas support to be a big boon, so I really appreciate that you
are maintaining it!
Regards,
Nathan
On Sun, Jun 19, 2016 at 7:45 PM, Greg Landrum
wrote:
> Dear Nathan,
>
> This came up a while ago on the list:
> http://www.mail-archive.com/r
Hi, Tim,
PandasTools.RenderImagesInAllDataFrames(images=True)solve the problem.
Here is a jupyter notebook example.rdkit 2020.03.2 pandas 1.0.3
-- Original --
From: "Tim Dudgeon"https://lists.sourceforge.net/lists/listinfo/rdk
Jensen ; RDKit Discuss
Subject: Re: [Rdkit-discuss] failed mols in converting SMILES to Pandas
dataframe Molecule
Hello Mike,
you could create a function with your if else structure and use apply on the
pandas dataframe. For example, if you have a SMILES column in your df:
def addMol
On 25/09/14 18:06, paul.czodrow...@merckgroup.com wrote:
Dear RDKitter,
on my new Windows laptop, I run into this issue:
"
import pandas as pd
import rdkit.Chem as Chem
from rdkit.Chem import PandasTools
"
=>
"
ValueError Traceback (most recent call last)
in ()
ay, October 31, 2019 2:17 AM
To: 'RDKit Discuss'
Subject: [Rdkit-discuss] calculating molecular properties on a Pandas dataframe
Molecule
Hi RDKit Gurus,
I've followed the docs and created a molecule column in my Pandas dataframe.
However, I do not seem to be able to do molec
On Fri, Jan 4, 2019 at 1:59 PM Jason Ochoada wrote:
>
> Thanks so much for taking the time to help! I didn't realize the size
> limit recommendation for pandas so maybe that's why I don't see much of it.
>
Yeah, Pandas is designed to keep the entire dataframe i
Awesome! Thanks for all the help!
Jason
On Sat, Jan 5, 2019, 1:21 AM Greg Landrum wrote:
>
>
> On Fri, Jan 4, 2019 at 1:59 PM Jason Ochoada wrote:
>
>>
>> Thanks so much for taking the time to help! I didn't realize the size
>> limit recommendation for pan
Hi Greg,
Thanks so much for taking the time to help! I didn't realize the size
limit recommendation for pandas so maybe that's why I don't see much of
it. I often work on much larger scale and was investigating moving from
KNIME to RDKit on Linux for that reason. The curve is j
h all pandas versions above 0.25.0, So I guess
for now the easiest fix is to downgrade pandas. Or you can use this method
which seemed to work for me:
from IPython.display import HTML
HTML(df.to_html())
I haven’t managed to downgrade pandas on Colab (almost certainly a Colab issue)
but the
Hello,
This might be trivial python question but I am stuck in calculating
the Chem.MolFromSmiles:
My smiles strings are in a pandas DataFrame (df) with SMILES column
(df.SMILES) and I have been calculating the mols (df_mol) by Pandas apply
function as below:
df_mol = df.SMILES.apply( lambda x
I think Nikolas is being a bit modest... the Pandas integration is
pretty cool. :-)
Here's an example of using it from the IPython prompt (it's better in
the notebook, but that doesn't paste so nicely into email)
Loading an SD file:
In [1]: from rdkit import Chem
In [2]: from rd
Yes, I can confirm that this is a problem caused by changes in Pandas
v0.25.x
Now we just need to figure out what those changes are and how to work
around them.
Here's a github issue to track the problem:
https://github.com/rdkit/rdkit/issues/2673
-greg
On Tue, Nov 5, 2019 at 12:21 P
to pandas
0.18.0 in conda. The command for that is:
conda install pandas=0.18.0
Best,
-greg
On Sun, Jun 19, 2016 at 6:29 PM, Nathan Lloyd wrote:
> If I add mol to pandas dataframe and try to visualize in table format using
> from rdkit.Chem.Draw import IPythonConsole
> a
:
Etc
But Pandas DF’s seem to being playing hard-ball.
Any thoughts?
Cheers,
mike
___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Hello Mike,
you could create a function with your if else structure and use apply on
the pandas dataframe. For example, if you have a SMILES column in your df:
def addMol(smiles):
if Chem.MolFromSmiles(smiles) is None:
Etc
return None # or whatever you
7;romol']=df2.apply(lambda x:Chem.Mol(str(x['pkl'])),axis=1)
PandasTools.RenderImagesInAllDataFrames()
del df2['pkl']
df2.head(2)
-greg
On Fri, Oct 25, 2013 at 4:43 PM, George Papadatos wrote:
> Question to rdkit pandas users (pandaskitters?):
>
> I managed to have t
:
Dear RDKitter,
on my new Windows laptop, I run into this issue:
"
import pandas as pd
import rdkit.Chem as Chem
from rdkit.Chem import PandasTools
"
=>
"
ValueErrorTraceback (most recent call
last)
in ()
1 import pandas a
Hi RDKit community,I would like to ask if it is possible to calculate (iterate
over) all the available descriptors for a set of compounds loaded in a pandas
dataframe.I have found a few examples doing the same with a "mols"
list.T
Hi all,
is it possible to manually add molecules to a pandas dataframe? I am
reading a bunch of mol2 files, adding some properties (including some
atom highlighting), then I'd like to add the resulting molecule to the
dataframe in order to show its depiction along with the data.
However, API
',))
>
> d = curs.fetchall()
>
> df2 = pd.DataFrame(d,columns=('molregno','pkl'))
>
> df2['romol']=df2.apply(lambda x:Chem.Mol(str(x['pkl'])),axis=1)
>
> PandasTools.RenderImagesInAllDataFrames()
> del df2['pkl']
> d
Hi RDKit Gurus,
I've followed the docs and created a molecule column in my Pandas dataframe.
However, I do not seem to be able to do molecular operations on the column.
For example, if you had a SMILES column, how would you calculate heavy atom
count and append this result to a new c
Hi,
I've tested the code below, and found out that put mol objects into pandas is
just straightforward.
[code]
#SMILES string list into mol objects, and then into dataframe
import pandas as pd
from rdkit import Chem
smiles = ['c1c1', 'c1c1O
Hi Riccardo,
I'm trying to understand your advice? Should I check if I have pandas
installed and uninstall it? Or installing pandas will help me with testing?
Anyway, I think there are two things worth mentioning:
1. I'm compiling it on raspberry pi
2. Installation failed - sudo ma
On Nov 24, 2013, at 11:58 PM, Nikolas Fechner wrote:
> if I remember correctly 10.1 was an intermediate pandas version where the
> HTML rendering in tables, that we use for rendering the structures, does not
> work as we need it. In this version pandas introduced an HTML escaping, which
Hi Michał,
Is pandas available in your test environment? I could reproduce a
similar problem on my own linux box, but it's apparently due to an
oversight in the PandasTools module that can raise an exception when
pandas is not imported. The interested output could be similar to the
following
Fechner wrote:
Dear all,
We developed a new module ( rdkit.Chem.PandasTools.py ) that allows
for using RDKit molecule objects directly in pandas dataframes. Pandas
(http://pandas.pydata.org/) is a python library that offers table-like
datacontainers, which are incredibly useful for anything rel
g/docs/source/rdkit.Chem.PandasTools.html#rdkit.Chem.PandasTools.SaveXlsxFromFrame>
Saves pandas DataFrame as a xlsx file with embedded images. molCol can be
either a single column label or a list of column labels. It maps numpy data
types to excel cell types: int, float -> number datetime -> datetime object
ame': lambda x:
x.replace('>', '')})
http://pandas.pydata.org/pandas-docs/stable/generated/pandas.read_csv.html
Pozdrawiam, | Best regards,
Maciek Wójcikowski
mac...@wojcikowski.pl
2016-03-11 11:12 GMT+01:00 Paul Czodrowski :
> Dear RDKitter & Pandas-
Hi Jason,
This gist shows how to generate fingerprints for the molecules in a pandas
dataframe and then use them to do similarity searches:
https://gist.github.com/greglandrum/045ccf8009fde91fc985864e70ee72a1
This is a reasonably efficient way of working with a smallish (<10K) number
ler
Sent: November 13, 2019 5:01 PM
To: rdkit-discuss (rdkit-discuss@lists.sourceforge.net)
Subject: [Rdkit-discuss] Random (?) highlighting in pandas dataframe
Hi all,
I have an issue with molecule rendering in a pandas dataframe. I read a csv
file with SMILES strings and names into a
ValueErrorTraceback (most recent call last)
in
1 frame = frame[["ROMol", "Smiles", "Core", "R1", "R2", "R3"]]
> 2 frame[&
Dear Samo et al.,
thanks for the code, Samo!
"mmp" is correctly depicted as reaction.
However, the depiction in a pandas data frame does not properly work.
The figure in the data frame is still "depicted" as
You can create new object that stores MMP and has default
If I add mol to pandas dataframe and try to visualize in table format using
from rdkit.Chem.Draw import IPythonConsole
and either
PandasTools.RenderImagesInAllDataFrames(images=True)
or
PandasTools.ChangeMoleculeRendering(frame)
I get the following error
Hi Mike
This should work
DF[‘HAC’] = [Chem.Lipinski.HeavyAtomCount(mol) for mol in DF[‘Molecule’]]
Best regards, Jan
On 31 Oct 2019, at 10.16, Mike Mazanetz
mailto:mi...@novadatasolutions.co.uk>> wrote:
Hi RDKit Gurus,
I’ve followed the docs and created a molecule column in my
Hi RDKitters,
I must have seen this in an ipython notebook but can't find it right now:
If I have a table of rdkit mols generated by the cartridge, is there a way
to retrieve them using a psycopg2 connection within python - ideally inside
a pandas dataframe?
I've got this snippet:
imp
ever, if I do the same in a loop inside a method of a class, and send
the output to a pandas dataframe, the match is not highlighted when
visualizing the dataframe.
Even more weird, if a store the molecule (after having applied
GetSubstructMatch on it) in a class field (e.g. self.test), and
I figured as much, and I guess in my case the pandas side will be useful
enough for this, thanks.
On Mon, 10 Jan 2022 at 14:05, Greg Landrum wrote:
> Hi James,
>
> The RDKit does not have a full-featured CSV parser, writing such a thing
> is a non-trivial task. If you need to sup
Good to hear that it is working now.
Thanks for the feedback,
Nikolas
>> On 26.11.2013, at 03:44, Andrew Dalke wrote:
>>
>> On Nov 24, 2013, at 11:58 PM, Nikolas Fechner wrote:
>> if I remember correctly 10.1 was an intermediate pandas version where the
>> HTM
Dear RDKitter & Pandas-Dataframes heavy users,
please find below a question concerning the conversion of pandas dataframes:
df = pd.DataFrame({"item": ["a", "b", "c", "d", "e"], "row1": [1,2,3,">2",5],
Hi,
Strange, I'm also using pandas 0.10.1, but it seems pretty obvious to me
that the problem is related to that, although it's not exactly clear to
me now why it should not happen at your system but on only on mine then :)
For the others following the conversation: Sorry for be
Hi all,
I am working on some molecules in a pandas DataFrame and have to export
them to a hdf file.
This works just fine but I get a warning about Performance due to mixed
types. (1)
Why are RDKIT Mol objects causing this warning in the first place? Am I
doing something wrong?
Please
ecule"] = mols
Best,
Christos
Christos Kannas
Scientific Software Developer (Cheminformatics)
On Thu, 25 Jul 2019 at 15:45, Gianluca Sforna wrote:
> Hi all,
> is it possible to manually add molecules to a pandas dataframe? I am
> reading a bunch of mol2 files, adding some propert
gist demonstrating:
https://gist.github.com/greglandrum/914ae66fd2f97addbbd472ae726567b1
-greg
On Thu, Jul 25, 2019 at 4:45 PM Gianluca Sforna wrote:
> Hi all,
> is it possible to manually add molecules to a pandas dataframe? I am
> reading a bunch of mol2 files, adding some propert
Hi all,
I have an issue with molecule rendering in a pandas dataframe. I read a csv
file with SMILES strings and names into a dataframe, and add a mol column to
the dataframe based on the SMILES. I then display the molecules in the
dataframe like so:
from IPython.display import HTML
HTML
[including rdkit-discuss, because it's relevant there and I'm pretty sure
Chris won't mind and the real Pandas experts may have a better answer than
me.]
On Wed, Nov 23, 2016 at 9:51 AM, Chris Swain wrote:
>
> I quite like storing molecules and associated data in a data
>
> ---
>
> ValueErrorTraceback (most recent call
> last)
>
> in
>
> * 1* frame = frame[["ROMol", "Smiles", "Core", "R1&
Dear Isidro,
I can’t test at the moment, but as I understand it so far I would guess the
reason for the behaviour is two-fold. First, the substructure search in the
pandas data frame just checks wether the substructure is present by calling the
HasSubstructMatch method from the molecule object
[0] == '>' else x}).dropna(axis=0)
Paul
Von: Maciek Wójcikowski [mailto:mac...@wojcikowski.pl]
Gesendet: Freitag, 11. März 2016 12:29
An: Paul Czodrowski
Cc: rdkit
Betreff: Re: [Rdkit-discuss] Pandas dataframe manipulation
Hi Paul,
I would suggest:
* assigning dtype of dataframe
Hard to say without seeing the data, but could it be that the pandas data
frame contains a bunch of molecules that are None?
-greg
On Tue, Oct 1, 2019 at 10:40 AM Guillaume GODIN <
guillaume.go...@firmenich.com> wrote:
> Dear All,
>
>
>
> I try this code on ‘Fre
Hi,
You can create new object that stores MMP and has default pandas and
ipython representation as base64 encoded png. This usually works for me,
but I'm not sure why in this case it works only for ipython representation
and not for pandas.. The code:
#
import pandas as pd
import rdkit.Ch
with *very*
long png strings, because the pandas maximal column width applies to
the string, which is what is stored in the dataframe, before the image
rendering. As an effect the truncated png string was shown in the
table (exactly the "...' ending shown in your example).
You could tr
Hi Niko,
I tried this piece of code adapted from the doctest and got the same
result (table is fine, but no rendering of molecules):
from rdkit.Chem import PandasTools
import pandas as pd
import os
from rdkit import RDConfig
from rdkit.Chem.Draw import IPythonConsole
from IPython.core.display
retty sure
> Chris won't mind and the real Pandas experts may have a better answer than
> me.]
>
> On Wed, Nov 23, 2016 at 9:51 AM, Chris Swain <mailto:sw...@mac.com>> wrote:
>
> I quite like storing molecules and associated data in a data frame and I’ve
>
Hi Everyone!
I'm a newbie making the shift from RDKit in KNIME to working with the full
package. I have been working (hacking) my through the tutorials I could
find pandas, Jupyter, RDKit etc. I'm using RDKit in the anaconda 3
environment. I'm struggling to figure out how to do
ting:
> https://gist.github.com/greglandrum/914ae66fd2f97addbbd472ae726567b1
>
> -greg
>
>
> On Thu, Jul 25, 2019 at 4:45 PM Gianluca Sforna wrote:
>>
>> Hi all,
>> is it possible to manually add molecules to a pandas dataframe? I am
>> reading a bunch of mol2 files, adding some properti
Thanks again for your reply. That's what I have tried:
from rdkit import Chem
from rdkit.Chem import AllChem
import pandas as pd
from rdkit.Chem import PandasTools
from rdkit.Chem.Draw import IPythonConsole
from IPython.core.display import HTML
df = PandasTools.LoadSDF(
Hi Both,
Many thanks for your rapid response, much appreciated.
Cheers
Chris
___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
https://pypi.python.org/pypi/chemfp/1.0
In my copious spare time, I've been trying to think of ways to embed this
directly in a pandas dataframe however, using them side by side is
certainly doable.
Cheers,
Brian
On Wed, Nov 23, 2016 at 10:06 AM, Peter Gedeck
wrote:
> Is it possible to
us Heller
>
> Sent: November 13, 2019 5:01 PM
>
> To: rdkit-discuss (rdkit-discuss@lists.sourceforge.net) <
> rdkit-discuss@lists.sourceforge.net>
>
> Subject: [Rdkit-discuss] Random (?) highlighting in pandas dataframe
>
>
>
>
> Hi all,
>
>
>
>
Hi Paul,
I am not sure if it is easily doable to get the pandas read_table function to
handle sd-files. However, there is some basic functionality for this already
built-in in the PandasTools module. If you check the docktest header there is a
small example. Basically,
frame
) works fine.
I've tried changing the PandasTools.molSize but it didn't help.
Here is my code:
from rdkit import Chem
from rdkit.Chem.Draw import IPythonConsole
from rdkit.Chem import PandasTools
import pandas as pd
from IPython.core.display import display, HTML
# Normal inli
nerated by the cartridge, is there a way
> to retrieve them using a psycopg2 connection within python - ideally inside
> a pandas dataframe?
>
> I've got this snippet:
> import pandas as pd
> import psycopg2
> conn = psycopg2.connect("port=5432 user=chembl dbna
all,
We developed a new module ( rdkit.Chem.PandasTools.py ) that allows
for using RDKit molecule objects directly in pandas dataframes.
Pandas ( http://pandas.pydata.org/) is a python library that offers
table-like datacontainers, which are incredibly useful for anything
related to data mining. Moreov
Yes, the way it is written it will only keep the last sdf file read. I can
think of 2 options:
1. You can concatenate all sdfs into one, multi-molecule file:
$ cat *.sdf > multi.sdf
And read this one.
2. Alternatively, instead of overwriting the final pandas dataframe every
time, you
Search and add similarity to resulting data frame
> On 27 Nov 2016, at 07:55, Greg Landrum wrote:
>
>
> You don't know if what could be done as a single line?
>
> -greg
--
who comes from the “cut and paste” school of scripting I’m always
concerned I’m asking something blindingly obvious
;-)
Chris
On 23 Nov 2016, at 12:36, Greg Landrum wrote:
[including rdkit-discuss, because it's relevant there and I'm pretty sure Chris
won't mind and the real Pa
Dear RDKitters,
I was wondering if anyone has looked into the Pandas data frame with
respect to read in a SD file similar to this syntax:
data =
pd.read_table(open('whatever.smi','r'),header=None,names=['smiles','cas','mutagenic'])
Ideally, &
That's a good question.
I'm not a master of pandas indexing, but this seems to work:
In [5]: sdf['mfp2'] = [rdMolDescriptors.GetMorganFingerprintAsBitVect(x,2)
for x in sdf['ROMol']]
In [8]: sims = DataStructs.BulkTanimotoSimilarity(qry,sdf['mfp2'])
In [13]
I just started playing around with the Pandas module, this is very cool
stuff. Thanks so much Nikolas for the contribution. I definitely owe you
a beer at the UGM. It might be worth noting that the you need to install
PIL in order to use the Pandas module. Everything will install without a
When developing the module I occasionally had problems with *very* long png
strings, because the pandas maximal column width applies to the string, which is
what is stored in the dataframe, before the image rendering. As an effect the
truncated png string was shown in the table (exactly the
Just for clarification, are you trying to render a dataframe or a series/single
column? The pandas series object has no to_html() method and is therefore
rendered as string only. Moreover, if you select a single column, e.g. 'ROMol'
from a dataframe by df['ROMol'] you will get
Hi rdkiters,
Due to popular demand I started to work on a function to export pandas
DataFrame to xlsx with molecule images embedded.
Because of the xlsx specifics the code is not optimal. The most annoying
thing about this implementation is that it has to write all images to the
hard drive
Hi Andreas,
Can you please send the full error message so that it shows the line
numbers, as well as the output of:
conda list | grep pandas
that will help diagnose the problem.
-greg
On Fri, Jun 3, 2016 at 4:44 PM, Andreas Schulz wrote:
> Hi,
> today I started a try with rdkit on Win
ry least, it gets
you more of the way there.
from rdkit.Chem import AllChem
from collections import Counter
import pandas as pd
def get_ecfp(mols, n=3, cut=10):
allfps = []
counts = Counter()
for i, mol in enumerate(mols):
fp = AllChem.GetMorganFingerprint(mol, n
you using?).
Best,
Niko
On May 8, 2013 at 9:51 AM Markus Hartenfeller
wrote:
> Hi Niko,
>
> I tried this piece of code adapted from the doctest and got the same result
> (table is fine, but no rendering of molecules):
>
> from rdkit.Chem import PandasTools
> import pa
1 - 100 of 337 matches
Mail list logo