Phenotype Systems Dashboard
dashboard/phenotype_systems.html (with a machine-readable twin,
dashboard/phenotype_systems.json) reports how the knowledge base's diseases
spread over the HPO top-level phenotype systems: Nervous System,
Musculoskeletal, Cardiovascular, and the twenty other direct children of
HP:0000118 (Phenotypic abnormality).
The browser's "Phenotype Systems" facet already tags each disease with every system any of its phenotypes falls under. That answers does this disease touch system X? and nothing more: a disease with forty nervous-system phenotypes and one skin finding counts in Integument exactly as a dermatological disease does. This page adds the weight behind the facet and the structure across it.
just gen-phenotype-systems # writes dashboard/phenotype_systems.{html,json}
just gen-dashboard # runs it as part of the full dashboard build
The page is derived output, regenerated by the generate-pages workflow, and is
never committed from a hand-authored PR (see page-build.md).
It reads app/hpo_category_cache.json, the HP-term-to-system map written by
just gen-browser-data, and never queries the ontology itself.
What it shows
Systems per disease. Two histograms on the same axis. Systems present is
the facet's count. Effective systems is exp of the Shannon entropy of the
phenotypes-per-system distribution, so a system holding one stray finding
barely moves it. The gap between the two medians is how much presence
overstates spread. At the time of writing the medians are 5 and 4.
Which systems travel together. A 23 × 23 matrix of every pair, coloured by lift: diseases in both systems divided by the number expected if the two were independent. Red pairs co-occur more than chance and blue pairs less; pairs that never co-occur are outlined. Hovering a cell gives the count, lift and Jaccard index. Two tables beside the matrix rank the strongest co-occurrences (lift, restricted to pairs with at least 25 diseases so a tiny system cannot top the list on two coincidences) and the most frequent pairs.
Exact combinations of systems. A degree-limited UpSet plot of the 30 most frequent exact sets of systems, preceded by a bar showing where every disease sits: in a combination unique to it, shared by two to four diseases, or shared by five or more. This panel exists mostly to show why an UpSet plot is the wrong primary view here. More than half the diseases have a combination no other disease shares, so the intersections an UpSet plot can draw cover under a fifth of the corpus.
All diseases. A sortable, filterable table of every entry with its phenotype count, systems present, effective systems, dominant system and the share of memberships that system holds, and the number of phenotypes whose HP term sits under two or more branches.
Two kinds of multiplicity
The page keeps two sources of "multiple parentage" apart, because they mean different things:
- A multisystem disease has phenotypes in several systems. This is what the presence count and the effective count measure.
- A multi-branch HP term sits under more than one top-level branch, because
HP is a DAG. Inguinal hernia (
HP:0000023) is both Digestive and Musculoskeletal; Proteinuria (HP:0000093) is both Genitourinary and Metabolism (both read fromapp/hpo_category_cache.json). One such phenotype puts a disease into two systems on its own. The page counts these once per system, exactly as the facet does, and reports them separately as "multi-system phenotypes" so a reader can see how much of a disease's spread is ontology structure rather than clinical breadth. Roughly a fifth of the phenotypes in the KB carry such a term.
Definitions
| Measure | Definition |
|---|---|
| System | One of the 23 direct children of HP:0000118. A phenotype belongs to every system its HP term descends from. |
| Systems present | Number of systems with at least one phenotype. |
| Effective systems | exp(−Σ pᵢ ln pᵢ), where pᵢ is the share of the disease's system memberships held by system i. Equals the presence count when phenotypes are spread evenly; approaches 1 when one system dominates. |
| Dominant system | The system with the most phenotypes; ties go to the alphabetically first. |
| Lift | Diseases in both A and B ÷ (diseases in A × diseases in B ÷ all diseases). |
| Jaccard | Diseases in both ÷ diseases in either. |
Phenotypes without an HP term, and HP-bound phenotypes whose term maps to no system (outside Phenotypic abnormality, or absent from the category cache), are counted in the JSON summary but do not contribute to any system.
Not in scope
The browser facet itself is unchanged, and the browser has no sort by these
measures. If a "most multisystem first" sort proves useful, the per-disease
numbers are already in the JSON and could be added to app/data.js by the
browser exporter. The design discussion that led here, including why a plain
UpSet plot was rejected as the primary view, is in
superpowers/specs/2026-09-13-phenotype-systems-overview-design.md.