# PAINS alerts among approved drugs

Data behind the ProteinIQ guide [PAINS filters](https://proteiniq.io/guides/pains-filters).

Last checked: October 29, 2026. We plan to rerun the analysis after each new ChEMBL release.

## Files

- `approved-drugs-pains.csv`: one row per approved drug (2,104 rows) with its ChEMBL ID, name, first approval year, oral and withdrawn flags, ATC class, whether it matches any PAINS alert and in which catalogue (A, B or C), the matched PAINS alerts and families, and the matched Brenk alerts. Structures (SMILES) are in the [approved drug library](https://proteiniq.io/datasets/small-molecule-drugs) under the same ChEMBL IDs.
- `summary.json`: every aggregate quoted in the guide, including the counts by family, alert, decade and therapeutic class, 95% Wilson intervals for each share, and the Brenk comparison.
- `analyze.py`: the script that produced both files. It is a copy of `scripts/pains-alerts-approved-drugs.py` in the ProteinIQ repository and imports `scripts/lipinski-ro5-chembl.py` from the same folder to select the drugs.

## Source and population

ChEMBL release 37 (ChEMBL_37, released May 1, 2026), read through the ChEMBL REST API on October 29, 2026. The population is the one used for the [Lipinski's rule of five](https://proteiniq.io/guides/lipinski-rule-of-five) analysis and ProteinIQ's [approved drug library](https://proteiniq.io/datasets/small-molecule-drugs): every molecule with `max_phase` 4, collapsed to its ChEMBL parent, keeping small molecules plus structurally defined peptides and oligosaccharides of at most 900 Da, and excluding biologics, inorganic and metal-containing structures, mixtures and parents without a structure. That leaves 2,104 drugs. See the Lipinski data README for the exclusion counts.

## Definitions

Alerts were matched with RDKit 2025.03.5 `FilterCatalog` on the ChEMBL parent structure, parsed from its canonical SMILES without adding explicit hydrogens.

| Column | Definition |
|---|---|
| `pains` | Matches at least one of the 480 PAINS substructures of Baell and Holloway (2010) in RDKit's SMARTS translation |
| `pains_a`, `pains_b`, `pains_c` | Matches an entry in RDKit's PAINS_A (16 entries), PAINS_B (55) or PAINS_C (409) catalogue |
| `pains_alerts` | Matched PAINS alert names, separated by semicolons. The number Baell and Holloway gave in parentheses, the size of the compound class in their screening library, is dropped |
| `pains_families` | Alert names without their final letter suffix, so `anil_di_alk_A` and `anil_di_alk_C` are both `anil_di_alk` |
| `brenk`, `brenk_alerts` | Matches any of the 105 unwanted-group rules of Brenk et al. (2008), and which ones |
| `first_approval` | Earliest ChEMBL first approval year across the parent and its salts; 1,805 drugs have one, the latest is 2024 |
| `oral`, `withdrawn` | ChEMBL oral route and withdrawn flags on the parent or any of its salts |
| `atc_level2`, `therapeutic_class` | Most common ATC level 2 group across the drug's ATC codes |

A PAINS match means the structure contains the substructure. It does not mean the drug interferes with assays.

## Reproduce

```bash
python scripts/pains-alerts-approved-drugs.py --cache-dir /tmp/lipinski-ro5
```

The script caches ChEMBL responses in the cache directory, the same cache as the Lipinski script. Delete it to read a new release.

## License

ChEMBL is licensed under [CC BY-SA 3.0](https://creativecommons.org/licenses/by-sa/3.0/), so these files are shared under the same license. Please credit ChEMBL (Zdrazil et al., Nucleic Acids Research, 2024) and ProteinIQ, with a link to https://proteiniq.io/guides/pains-filters.
