Re: [Rdkit-discuss] SAR matrices
This is a great problem, but it's certainly not a trivial one. It's a bit of a triviality, but here's at least a demo of how to draw the R groups with the dummies as "attachment points": https://gist.github.com/greglandrum/f7e310045542ab71447351a8043bbf3f -greg On Sun, Aug 18, 2019 at 2:43 PM ken wrote: > Hello, > > I am trying to build a 2-D R-group grid (or table, or spreadsheet), where > the row headers contain R1 values and the column headers contain R2 values > (or vice versa). Compounds that have given R1 and R2 groups would be > represented on the table as a filled cell that intersects those R1 and R2. > For example, the input could be an SD file containing the following three > compounds: > > The desired output grid from the sd file would look something like this > ("Y" can be replaced with cell formatting or some other indicator): > > The closest thing to this that I have been able to find is the "SAR > Matrix" (https://f1000research.com/articles/3-113/v2), but the code that > was used to generate the matrices does not appear to be available. Does > anyone happen to have such code or know how I can generate it? I imagine > the first step would be to perform an R-group decomposition, but I'm not > sure what to do from there. > > I started to see if I could build the program from scratch, but then I > thought that someone must've done this before and I shouldn't needlessly > reinvent it. I've been (re)learning Python for the past year or so and I > *think* I have a pretty good handle on the language, but I wouldn't mind > putting said learning to the test on a "real" project, so if anyone has a > solution that outputs something that even vaguely resembles the desired > grid/matrix, maybe I can modify it to fit my needs. > > At some point, I would need the grid to be editable in Word, but I'll > cross that bridge when I get to it... > > Thank you in advance for your help, > Ken > ___ > Rdkit-discuss mailing list > Rdkit-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rdkit-discuss > ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] SAR matrices
Hi Hongbin, Thank you for your reply. I will take your suggestions as a good starting point. I too was afraid that I underestimated the difficulty of the task... That's an interesting point regarding the examples in the recited paper; one of the cited papers (https://pubs.acs.org/doi/10.1021/ci300206e) seemed to suggest that the matrices were made "with aid of RDKit," but I may have read too much into that. I did know that StarDrop could produce such tables, but it has some limitations (with respect to my specific needs) that motivated me to try to devise a more customized solution. I just learned (like an hour ago) that my organization has a license to this software, so I will see if I can live with its limitations in the short term while I work on my own solution. Thanks again! Ken On Sun, Aug 18, 2019, at 11:27 AM, Hongbin Yang wrote: > > Hi Ken, > > I am afraid that you may have underestimated the amount of your demand. At > least it includes R group decomposition (and it seems that only two > substitutes are considered in your example), drawing molecules, and rendering > the “table”. > > You can use RDKit to decompose the compounds. For example, use maximum common > substructure to setup the scaffold, followed by identification of the > connecting points by comparing the the compounds and the scaffold. > > As for drawing molecules, I think RDKit cannot draw the substituent group > (I’m not sure) like what ChemDraw does. > > If you just want to analyse the compounds by R-group decomposition, I believe > some kinds of commercial software such as Schrodinger and StarDrap are pretty > good. > > And as for the example in the paper by Gupta-Ostermann et al. I guess that > they drew the figures via ChemDraw and Powerpoint rather than scripts. > > Best regards, > > > > Hongbin Yang 杨弘宾, Ph.D. > Research: Toxicophore and Chemoinformatics > On 08/18/2019 20:23,ken wrote: >> Hello, >> >> I am trying to build a 2-D R-group grid (or table, or spreadsheet), where >> the row headers contain R1 values and the column headers contain R2 values >> (or vice versa). Compounds that have given R1 and R2 groups would be >> represented on the table as a filled cell that intersects those R1 and R2. >> For example, the input could be an SD file containing the following three >> compounds: >> >> The desired output grid from the sd file would look something like this ("Y" >> can be replaced with cell formatting or some other indicator): >> >> >> >> The closest thing to this that I have been able to find is the "SAR Matrix" >> (https://f1000research.com/articles/3-113/v2), but the code that was used to >> generate the matrices does not appear to be available. Does anyone happen to >> have such code or know how I can generate it? I imagine the first step would >> be to perform an R-group decomposition, but I'm not sure what to do from >> there. >> >> I started to see if I could build the program from scratch, but then I >> thought that someone must've done this before and I shouldn't needlessly >> reinvent it. I've been (re)learning Python for the past year or so and I >> *think* I have a pretty good handle on the language, but I wouldn't mind >> putting said learning to the test on a "real" project, so if anyone has a >> solution that outputs something that even vaguely resembles the desired >> grid/matrix, maybe I can modify it to fit my needs. >> >> At some point, I would need the grid to be editable in Word, but I'll cross >> that bridge when I get to it... >> >> Thank you in advance for your help, >> Ken > > *Attachments:* > * r_matrix example01.png > * r_matrix example02.png ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
[Rdkit-discuss] FreeSASA surface coordinates
Hello, everyone I was wondering if there is any way to access the surface coordinates calculated on individual atoms from the FreeSASA package? Illimar Rekand Ph.D. candidate, Brenk-lab, Haug-lab Department of Biomedicine Department of Chemistry University of Bergen ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Get distances between two atoms in different molecules
Thanks, this worked like a charm! I was wondering on another thing: I wanted to calculate the bond angle between three atoms in the two conformers (essentially looking for possible hydrogen bonding). Again, rdMolTransforms.GetAngleDeg() inputs only one conformer, while the Point3D angle functions inputs either two or four atom indices. Is there some function I've either misunderstood/missed or is it better to retrieve this angle from vector calculations? Illimar Rekand Ph.D. candidate, Brenk-lab, Haug-lab Department of Biomedicine Department of Chemistry University of Bergen From: Paolo Tosco Sent: Friday, August 16, 2019 4:33:36 PM To: Illimar Hugo Rekand Cc: rdkit-discuss@lists.sourceforge.net Subject: Re: [Rdkit-discuss] Get distances between two atoms in different molecules Hi Illimar, You may use Point3D.Distance: conf_a.GetAtomPosition(i).Distance(conf_b.GetAtomPosition(j)) Cheers, p. > On 16 Aug 2019, at 16:01, Illimar Hugo Rekand wrote: > > Hello everyone, > > > I see that GetBondDistance() is a useful tool for calculating the distances > between atoms, whether bonded or nonbonded. However, I am unsure on how to > implement this function to calculate distances between atoms in different > molecule, as the functions requires a conformer as an argument. > > > Would I need to generate a conformer containing both molecules in order to > use this function for calculating the intermolecular atom distances? > > > Illimar Rekand > Ph.D. candidate, > Brenk-lab, Haug-lab > Department of Biomedicine > Department of Chemistry > University of Bergen > > > > ___ > Rdkit-discuss mailing list > Rdkit-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rdkit-discuss ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss