Adding CDC growth reference standards to the O3 Growth Chart

Hi Everyone,

I’ve been reading through `openmrs-esm-patient-growth-chart-app` and running it locally, and I’d like to propose adding CDC growth references alongside the existing WHO ones. Before writing any code I wanted to check the approach with people who know this module better than I do.

**Where things stand.** The module ships WHO weight-for-age for birth to five years and renders it well. Patients over five hit an empty state. The README already lists CDC as in scope, so this is filling in something that was planned rather than proposing a new direction.

**What I found while working out where a second dataset would go.** Most of the chart is shaped around there being exactly one — the percentile list, the colour map, the axis ticks, the chart title and the age cutoff are all literals in `growth-chart.utils.ts` and `growth-chart.component.tsx`. That’s a completely reasonable way to ship a first vertical slice, but it means adding CDC is mostly a de-hardcoding job rather than a data drop.

One thing genuinely blocks the simple approach: **CDC publishes no 15th or 85th percentile for weight-for-age.** Those columns exist only in the BMI-for-age and weight-for-stature tables. CDC’s chart uses 3/5/10/25/50/75/90/95/97 where WHO’s uses 3/15/50/85/97 — that’s what each body’s printed chart actually shows. So the curve set has to become a property of the dataset rather than a global constant. WHO’s chart then stays exactly as it is today, and CDC draws its own.

CDC also splits weight-for-age across two files (birth–36 months, and 2–20 years) that overlap. I’m proposing the 24-month switch point CDC’s own SAS program uses, implemented in a committed generator script so the data is reproducible rather than hand-converted.

**The payoff** is that five- to twenty-year-olds get a real chart instead of an empty state, since CDC weight-for-age runs to 20 years.

I’ve written the detail up properly — investigation notes with file references, the proposed refactor with before/after code, requirements, test plan, and a two-PR delivery plan:

PROPOSAL LINK (CDC-Growth-Chart-Proposal - Google Docs)

A few things I’d genuinely like input on before I start:

1. Should WHO remain the default standard for all deployments, or should that be per-distro?

2. Nine CDC curves as published, or subset to five for visual parity with the WHO chart?

3. Would you rather extend WHO to its 5–19 reference than add CDC? Its weight-for-age component stops at 10 years, which is what led me to CDC — but that’s a deployment-context call, not a technical one.

4. Is turning the over-five empty state into a chart acceptable as default behaviour, or should it sit behind config for a release?

One unrelated thing I ran into and mention in the proposal: the stylesheet’s line-styling rules use the Carbon v10 `bx–` prefix, but `@carbon/[email protected]` only emits `cds–`, so the dashed reference curves and the bold patient line never actually apply. Happy to send that up as a small separate fix first if that’s easier to review.

I’m flexible on scope and happy to split this differently, or set it aside if it isn’t a priority right now. I’ll file a Jira ticket once there’s rough agreement on direction.

Thanks! @lumuchris256 @anjisvj @grace @jayasanka @dilankavishka

Hey @sudeshkar! thank you for your interest in doing this project.

We should keep the WHO reference data as the default reference for the growth chart, and we should implement the CDC as a configurable option. this means that if any implementer wants to add CDC references, they would be able to simply enable CDC using the configurations.

BTW, I would suggest that before we implement the CDC charts, we should do some more research and gather more feedback on how we’re going to implement this.

More than that, our focus is on getting the growth chart into the patient-chart repo because it’s currently living in its own repo. also, we need to add height-for-age charts using the WHO references.

Thanks.

1 Like

Thanks @dilankavishka — that’s a helpful steer, and I’m happy to fit CDC around the current priorities rather than ahead of them.

I agree with the direction: WHO should remain the default reference, with CDC as an opt-in configuration if and when it becomes useful. That also settles my questions about the default behaviour, so I’ll set those aside.

I also wanted to correct one thing from my earlier post. I mentioned sending the bx--cds-- stylesheet fix as a separate PR, but after looking more closely I saw that @dennis PR #10 already covers it (and more thoroughly than I was planning to). I’ve pulled the branch, tested it against dev3, and I’ll leave my feedback there instead of duplicating the work.

I also went back and read O3-5448. Burke had already raised the question of using WHO’s 5–19 references, and the phased approach there was to finish and deploy the 0–5 work first before expanding further. That makes sense, so I’ll follow that sequencing rather than push CDC ahead of it.

One implementation detail that might be worth keeping in mind for the future is that WHO’s 5–19 references only extend weight-for-age to 10 years (while height-for-age and BMI-for-age continue to 19). I don’t think that changes the current roadmap, but it’s probably useful context when the 5–19 work comes around. CDC was only interesting to me because it extends weight-for-age to 20 years, so if implementers don’t have a need for that, I’m perfectly happy for O3-5834 to stay in the backlog.

In the meantime, I’d be happy to help wherever it’s most useful. I can continue reviewing and testing PRs, or take on some of the refactoring work needed to make the chart configuration data-driven if that would help the height-for-age work. If there’s another issue that’s a higher priority, I’m happy to work on that instead.

Thanks again for the guidance.