Skip to content

Surface profile data caveats as a per-track warning in OncoPrint - #5637

Draft
inodb wants to merge 1 commit into
cBioPortal:masterfrom
inodb:oncoprint-track-caveat
Draft

Surface profile data caveats as a per-track warning in OncoPrint#5637
inodb wants to merge 1 commit into
cBioPortal:masterfrom
inodb:oncoprint-track-caveat

Conversation

@inodb

@inodb inodb commented Jun 30, 2026

Copy link
Copy Markdown
Member

What

A molecular profile whose profile_description contains a Caveat: marker now shows a ⚠ warning icon on every OncoPrint track from that profile, with the caveat text in a hover tooltip. This lets study curators flag how data should be interpreted — e.g. cell-type fractions derived from a sorted cell population — without the caveat being buried in the profile description where viewers won't see it.

Motivating case: the msk_spectrum_tme_2022 single-cell cell-type fraction profiles are derived from CD45 FACS-sorted scRNA-seq, so a sample's composition reflects its sort gate (some samples are immune-only or non-immune-only) rather than whole-tumor cellularity. A 100%-summing stacked/heatmap track is misleading without surfacing that.

Screenshot

Each cell-type track shows a ⚠ (the genetic BRCA1 track is unaffected — numeric percents still render). Hovering the ⚠ shows the caveat text, e.g. "Fractions are derived from CD45 FACS-sorted scRNA-seq, so each sample composition reflects its sort gate (some samples are immune-only or non-immune-only) rather than whole-tumor cellularity."

Caveat warning icons on generic-assay tracks

(Captured locally with the caveat injected, since the live study data doesn't carry the Caveat: marker until cBioPortal/datahub#2342 merges — the deploy preview won't show the ⚠ until then.)

How

  • getProfileDescriptionCaveat() parses the Caveat: marker (case-insensitive) from a profile description.
  • The generic-assay heatmap and categorical track builders set the ⚠ glyph + caveat tooltip when the profile is caveated.
  • IHeatmapTrackSpec / ICategoricalTrackSpec gain infoTooltip (genetic tracks already had it); wired through DeltaUtils to $track_info_tooltip_elt.
  • oncoprintjs: the track-info view now renders non-numeric info verbatim instead of coercing it to N/P, so the ⚠ glyph displays. N/P is still shown for the not-profiled sentinel and numeric percents are unchanged.

The convention is generic — any profile gets the warning for free by writing Caveat: … in its description. Companion datahub change: cBioPortal/datahub#2342. Docs change to follow.

Preview

🤖 Generated with Claude Code

A molecular profile whose profile_description contains a 'Caveat:' marker now
shows a warning icon on every OncoPrint track from that profile, with the
caveat text in a hover tooltip. Lets curators flag how data should be
interpreted (e.g. cell-type fractions from a sorted population) without the
caveat being buried in the profile description.

- getProfileDescriptionCaveat() parses the 'Caveat:' marker from a description
- generic-assay heatmap & categorical track builders set the warning + tooltip
- IHeatmapTrackSpec / ICategoricalTrackSpec gain infoTooltip (genetic tracks
  already had it), wired through DeltaUtils
- oncoprintjs track-info view renders non-numeric info verbatim instead of
  coercing it to 'N/P', so the glyph displays (N/P still shown for the
  not-profiled sentinel; numeric percents unchanged)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JEbP4a7tGv74r3RtNYt7Jw
@netlify

netlify Bot commented Jun 30, 2026

Copy link
Copy Markdown

Deploy Preview for cbioportalfrontend ready!

Name Link
🔨 Latest commit 8fc1595
🔍 Latest deploy log https://app.netlify.com/projects/cbioportalfrontend/deploys/6a444723011c280008522e61
😎 Deploy Preview https://deploy-preview-5637.preview.cbioportal.org
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants