Skip to content

Study View filter bar: generic-assay filters named by their chart, a row, value or interval per pill (STV-FB-3 #13, #14) - #498

Open
alisman wants to merge 1 commit into
masterfrom
studyview-assay-pills
Open

alisman wants to merge 1 commit into
masterfrom
studyview-assay-pills

Conversation

@alisman

@alisman alisman commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The filter bar now names a generic-assay filter by its chart, as the portal does: " : or ", each pill removable (STV-FB-3 #13, #14; UserSelections genericAssaySelectionFilters / genericAssayDataFilters). Before, these were the generic clause pills.

  • Frequency tables (Timeline view: one patient's clinical timeline, with opt-in patient-level federation over MCP #13): "Frequency Table: Putative arm-level copy-number from GISTIC : 18p Loss or 17p Loss". There is a pill per checked row, named by the row's entity as the table names it.
  • Generic-assay charts (Method notebooks: download a view's script, data and check as .ipynb; drop JupyterLite #14):
    • a categorical chart's values: "8q: Putative arm-level copy-number from GISTIC : Gain";
    • a numeric chart's bar as an interval, "0.1 < x ≤ 0.2", its ends editable as a clinical chart's are.
  • A pill's ×:
    • a row or value leaves the others;
    • an entity's last row takes its part of the filter;
    • the chart's last pill takes the filter.
  • "and": two filters in a row from one chart (two bars clicked) are joined by "and" (STV-FB-2).
  • Naming:
    • by the chart when the entity is charted;
    • else by the profile's frequency table when one is drawn (a filter over several entities can only be the table's);
    • else as the chart would be titled (": ").
  • No new clause field: the leaves are read as they are.

Spec IDs

Verification

  • Browser, dev server, coadread: the arm-level CNA frequency table, 18p Loss and 17p Loss applied.

    • The bar reads "Frequency Table: Putative arm-level copy-number from GISTIC : 18p Loss or 17p Loss", the table's own row names.
    • × on 18p Loss leaves "… : 17p Loss".
    • No page errors.
  • Unit tests: test/study-view-pills.test.ts, "generic-assay pills":

    • a frequency table's rows named by entity, under the table's name;
    • a numeric bar's interval and its edit, which keeps the generic-assay leaf;
    • a row's ×, an entity's last row, and a chart's last pill;
    • a categorical chart's values, and the fallback name;
    • "and" between two filters of one chart.

    npm test 7,196 pass, 0 fail; tsc --noEmit and eslint clean.

  • Coverage: passes.

  • Planted bugs: 4 in scripts/mutants/study-view/assay-pills.ts (guard unit).

Tracker

Under "Study View → filters, actions and tabs", this line (docs/PORTAL-PARITY.md:483, as #489 left it):

becomes:

Scorecard 31-study-view-shell.md, row STV-FB-3 (as #489 left it: | STV-FB-3 | 🟡 | B | Clinical (incl. NA) named by the chart's display name, a pill per value or range; gene-table selections a pill per gene coloured by alteration (geneTablePills); gene-chart and mutation-type filters "<chart> : <state> or <state>", each removable (geneStatesFilter); GA, case-list, event and derived clauses still the generic pills; no group-filter or treatment pills |):

| STV-FB-3 | 🟡 | B | Clinical (incl. NA) named by the chart's display name, a pill per value or range; gene-table selections a pill per gene coloured by alteration (geneTablePills); gene-chart and mutation-type filters " : or ", each removable (geneStatesFilter); generic-assay frequency-table rows, values and intervals by their chart, each removable, intervals editable; case-list, event and derived clauses still the generic pills; no group-filter or treatment pills |

Preview

/lab?tab=explore&study=coadread_tcga_pan_can_atlas_2018: in the arm-level CNA frequency table, check two rows and Apply filter.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Q3ezTaCo6wHFVsML6Qd4ht


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

…row, value or interval per pill (STV-FB-3 #13, #14)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q3ezTaCo6wHFVsML6Qd4ht
@vercel

vercel Bot commented Nov 19, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
cbiolab-genie Ready Ready Preview Nov 19, 2026 10:37pm UTC
cbiolab-new Ready Ready Preview Nov 19, 2026 10:37pm UTC
cohort-lab Ready Ready Preview Nov 19, 2026 10:37pm UTC

Request Review

This branch was successfully deployed

1 active deployment
Preview – cohort-lab — 64470e9a Deployed Nov 19, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant