Name: Generate 2D SAR Table
Author: Andrei Caracoti
Version: 1.0
Purpose: This protocol reads a core structure (marked or not with the R attachment points) and a set of molecules that contain the core, then it generates the SAR information and creates a table with R1 on the Y axis and R2 on the X axis. An activity value is shown in the table and color-coded.
Requirements: Pipeline Pilot 6.0 or later, Reporting Collection
Limitations: none known
Contents: Generate 2D SAR Table.xml

The new example requires Pipeline Pilot 7.5 or later.
Let us know if you have any feedback.
Here's two example protocols that make use of the Cross Tab Data Connector and ToolTip components to create a richer more extensible version of the 2D SAR table.
In addition to showing the full compound structure in the mouseover tooltip, the compound ID (or any other data record property) can be appended to the image.
The first zip file shows the classic Benzoxazole example, which contains just 2 R groups. The second example contains a Quinazoline core with up to 5 R-group positions enumerated. R1, R3, R5 are positioned on the Columns and R2, R4 in the rows (arbitrarily decided to go with Odd R group numbers for columns and Even R group numbers for rows).
This version can handle compounds with up to 8 R groups. If you need more, this can be readily accomodated.
Regards,
Adrian.
Regards,
Adrian.
Thanks to the customer that spotted this!
A.
Hi Adrian,
I have a question concerning this table. Is it possible to introduce more than one core? I have the left structure as core but got a list with a tautomer form when R2 = H. If I include two cores I get them into the table but also fake entries which originally don't exist in the list. Since I'm unexperienced in pipeline pilot I have aboslutely no idea where to start.
Apart from my small problem this is really a great tool!
Thanks a lot!
Cheers,
André
Hi André,
With multiple core, you'd have to identify matching R-groups on each core if your aim is to generate a single table.
One thing you can do is collapse into a run to completion subprotocol from the "generate SAR" component" to the "html report" (excluded), then group by tag before the subprotocol, where tag would be the core canonical smiles string (beware that case sensitivity would be required to group on smiles strings), and don't forget to ungroup at the start inside the subprotocol. Can't provide you with the protocol, I don't have access to PP at the moment. What you should get is a repeated table per core structure. Beware that data connectors might get confused with the repeating tables, you should probably get rid of them at the first trial.
Cheers,
Pierre
Hi Adrian,
thank you very much. I tried to follow the pipeline but it is indeed nearly impossible for me. So I prepared an SD file with random activity data and ID numbers. The structures contain some duplicates but with different activity data (shouldn't be possible but I got such a list and your pipeline handles that very well) and two different cores (the two relevant tautomers) that are also attached in a separate sd file.
Thank you very much again for this valuable tool.
Cheers,
André
Hi André,
As Pierre correctly suggests, we should be able to deliver multiple scaffold-based 2D SAR tables using run-to-completion sub-protocols. This is probably a lot to ask of a new user, so I will see if I can build a version that handles this for you. Is your data proprietary, or do you have a non-confidential example? If you have an example that is not confidential, would you be prepared to send me a copy of it, so that I can test the protocol against?
Best,
A.
Actually, the protocol is far too complex to be hacked the way I proposed. Indeed, it uses global variables to store RgroupLists which one needs to turn to subprotocol local variables. Not going into more details, I'm sure Adrian will help you with his protocol.
With regards to your initial question the main point in Adrian's protocol is the use of the cross table. You may use it either from wide table or tall skiny (unpivoted, see second example). The joined examples are not as nice as Adrians in terms of display, but way simpler to understand.
Cell may contain arrays because the cores I used contain more than one R-group, the cross table doesn't compute the average although it's setup for this.
As you'll see, the first part of the protocol prepares the data and cores (from smiles) and you get as many tables as cores.
Hope this helps,
Pierre
Hallo Pierre,
yes, that's much easier to understand. Thank you. This helps me to get more familiar with Pipeline Pilot.
But I'm also looking forward to Adrian's pipeline.
Cheers,
André
Hi Horat,
Here's a replacement protocol that now handles multiple cores. I've pre-configured it to use your input set. One thing to note is that the cell coloring is not yet working quite right. If a table has cells with multiple fields, then it limits the cell color to the numeric property only. If the cells have no more than one property each, then the cells have the correct background color scheme.
Let me know how you get on.
A.
Hi Adrian,
that's a really nice feature with the tabs and will surely help when it comes to really different cores. But I had hoped to get two cores in one table because my problem is that I have two tautomeric forms that coexist in solution. In the list they are drawn either as left or right structure (picture below). So I hoped to get both tautomers (cores) with their R1 and R2 in one table.
Thank you,
cheers
André
Hi Mike,
No, the CrossTab component doesn't sort its input - it generates the row and column order simply by the order that the row/column categories are received. Therefore, to control the order of rows and columns you need to sort the input data upstream of the CrossTab.
Cheers,
Andrew
Hi Mike,
Nice to hear from you! As Andrew mentions above, the 2DSAR Table uses the Crosstab component. This builds each table based on the order the groups appear in. It is possible to sort compounds by multiple fields (e.g., R1, R2) upstream before they pass into the Crosstab. However, the absolute may still vary, if the same R-group substitution combinations don't appear in each case.
A.
...in which case you need to create dummy entries upstream, ahead of the sort operation, which will cause an empty row/column to be created by the CrossTab.
Hi Adrian,
Is it possible to order the rows and columns of a crosstab table?
I have multiple scaffolds, each with the same sets of R-groups. I am generating a crosstab table for each scaffold, these appear in the web page one above another.
I had assumed that crosstab tables generated in the same way would have the rows and columns in the same order but this is not the case, so my output is untidy.
Is there any solution to this problem?
Thanks
Mike