Repository navigation
feat(app): add QMRA wiki library, pooling, and pooled-data exploration - #40
Merged
Merged
Conversation
Upload the QMRA wiki workbook (or use a 14-experiment sample), filter experiments by normalised metadata, and plot preferred-model curves faceted and coloured by pathogen group, outcome, dose unit, host, route, or model. One fittable experiment can be sent to the Data and Fit tabs with its study id, host, unit, and endpoint. Groundwork for #35.
The Data tab is now the single place to load data: delimited files and
the Ward example become the dataset Fit analyses, while an .xlsx QMRA
wiki workbook (or the bundled sample) is loaded for the Library tab,
which keeps exploration and send-to-Fit. A bad workbook reports its
error and keeps the previous one.
The Library plot no longer collapses in the fillable layout ("figure
margins too large"), and narrow facets get power-of-ten dose labels
and wrapped panel titles.
poolability_test(), fit_pooled_dose_response(), poolability_combinations(), and group_datasets() now check dose_unit metadata before fitting. When any dataset records a dose_unit, every dataset must record one and all must name the same unit (ignoring case and surrounding spaces); otherwise the error lists each dataset's unit. Datasets without unit metadata are not checked. Hosts and endpoints are still not enforced. Refs #21. BREAKING CHANGE: calls that pooled or tested datasets recording different dose units, or a unit on only some datasets, now error instead of running.
Choose a pooling set on the Library tab and test it on the new Pooling tab with singlehit's poolability_test() and fit_pooled_dose_response(). A written rationale is required before each run, and every run goes into a session log (rationale, acknowledged warnings, p-values, workbook) that counts unadjusted tests and downloads as CSV. Results show the LRT with a low-power caveat, separate versus pooled fits, the spread of parameter estimates, and the wiki's own pooled entry when one matches (21 + 23 reproduces the wiki's "21,23"). Data-driven grouping is not offered. The checks live in one pool_rules table and are a deliberately loose, tunable first cut: only data problems and dose units block; outcome, host, route, and pathogen differences warn. Refs #35, #20.
- Add strain/isolate metadata and filters to the experiment library - Add exploratory poolability grouping, logging, and data-informed set notices - Send pooled experiments to Data and Fit; add Cryptosporidium sample data and pooling article
- Carry per-experiment dose groups into Plots and Explore - Colour pooled observations by sub-study metadata and inspect fitted values
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Testing
Rscript dev/run_tests.R— 516 tests passed.