Support NMR Chemical Shifts #8

Open
opened 2026-04-12 16:35:31 -04:00 by aalexmmaldonado · 0 comments
aalexmmaldonado commented 2026-04-12 16:35:31 -04:00 (Migrated from github.com)

NMR data is structurally different from scalar properties. A single compound may produce dozens of chemical shift values, one per atom or peak. The output DataFrame will have one row per peak, not one row per compound. And PubChem may store this data under "NMR Spectra", "Chemical Shifts", or something else entirely. Nobody should guess.

Scope

Start by calling PubChemAPI.get_annotations() and searching for NMR-related headings. Document what you find in the PR description. Then add the appropriate Annotation member.

Create pcdigitizer/data/nmr.py with an NMRData processor. Proposed output schema: cid, sid, pclid, nucleus (String — "1H", "13C"), shift_ppm (Float64), multiplicity (String, nullable), coupling_Hz (Float64, nullable), assignment (String, nullable), comment (String, nullable). This schema will probably need revision once you see real data.

NMR data may arrive as a single long string containing all peaks, or as separate data points per peak. Explore before committing to a schema. This issue may need to be scoped down after the exploration phase. Filing a follow-up issue is fine.

Register, export, and test.

Definition of done

A working processor for at least one NMR data type (¹H or ¹³C), or a well-documented write-up explaining why the data format requires a different approach.

NMR data is structurally different from scalar properties. A single compound may produce dozens of chemical shift values, one per atom or peak. The output DataFrame will have one row per peak, not one row per compound. And PubChem may store this data under `"NMR Spectra"`, `"Chemical Shifts"`, or something else entirely. Nobody should guess. ### Scope Start by calling `PubChemAPI.get_annotations()` and searching for NMR-related headings. Document what you find in the PR description. Then add the appropriate `Annotation` member. Create `pcdigitizer/data/nmr.py` with an `NMRData` processor. Proposed output schema: `cid`, `sid`, `pclid`, `nucleus` (String — "1H", "13C"), `shift_ppm` (Float64), `multiplicity` (String, nullable), `coupling_Hz` (Float64, nullable), `assignment` (String, nullable), `comment` (String, nullable). This schema will probably need revision once you see real data. NMR data may arrive as a single long string containing all peaks, or as separate data points per peak. Explore before committing to a schema. This issue may need to be scoped down after the exploration phase. Filing a follow-up issue is fine. Register, export, and test. ### Definition of done A working processor for at least one NMR data type (¹H or ¹³C), or a well-documented write-up explaining why the data format requires a different approach.
Sign in to join this conversation.