alvaroingold / atlas-cbs-ipm

AtlasCBS is a tool that allows you to explore chemico-biological space using Ligand Efficiency Indices (LEIs)
1 stars 0 forks source link

Count character 'n' for NPOL SMILES #1

Closed alvaroingold closed 8 years ago

alvaroingold commented 8 years ago

Bug in the 'on the fly' counting of NPOL, when the SMILES contain a character 'n' (lower case N), meaning that they are included in aromatic rings. This needs to be corrected, as this problem is very prominent whe using the import CSV, SMI feature

alvaroingold commented 8 years ago

Fixing to count the lower case 'n' carried out with SMARTS. According to Daylight examples:

Acceptors are defined as nitrogen or oxygen:
[N,n,O,o] or [#7,#8]

The current code implements the following parsing strategy for SMARTSQueryTool at classes 1. LEIaddCompound 2. LEIupdateCompound 3. LEIuploadSMI 4. LEIuploadCSV

==> SMARTSQueryTool querytool = new SMARTSQueryTool("[N,n,O,o]");
boolean status = querytool.matches(ac);
if (status) { npol = querytool.countMatches(); }                                                                        
alvaroingold commented 8 years ago

Issue fixed by commit 4de8eaaaa180da7855886601c8338450a6448a23