Enhancement: Support sensitivity analyses in Strategus Cohort Method shell
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 12
- Forks
- 8
- Avg merge
- 2m
- Merged PRs (30d)
- 12
Description
Summary
I have been updating the Strategus cohort-method workflow to better support multiple CohortMethod analyses, including sensitivity analyses.
Before opening a pull request, I wanted to check whether this direction looks reasonable and whether you would prefer any additional changes to be included first.
What Changed
- Added support for sensitivity analyses in the cohort-method workflow.
- Updated cohort-method prompts and JSON templates for so multiple entries can be represented in fields such as:
studyPeriodstimeAtRiskspsSettingsoutcomeModels
- Updated the Strategus cohort-method shell to support adding sensitivity analyses during step-by-step configuration.
- Refactored
06_cm_spec.Rgeneration so the script reads the saved JSON artifacts and builds the Strategus CohortMethod specification directly, instead of relying on analysis objects already constructed by the shell.
Compatibility
This change is focused on the cohort-method analysis-setting and script-generation path.
No broader ACP functionality was changed, so the risk of conflicts with unrelated ACP flows should be low.
Additional Suggestion: renv Support
The generated scripts currently target the latest HADES package versions. What do you think about using renv to make package dependencies more reproducible?
After the shell finishes, it currently writes the generated R scripts under scripts/. We could also generate an renv setup for the output project and add restore code to the generated scripts, so users can restore the package versions expected by those scripts.
I have not opened the pull request yet. If this direction looks reasonable, I can also add renv support before sending the PR.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the cohort-method prompts and JSON templates, then trace how the shell produces the saved artifacts and how 06_cm_spec.R reads them. Check the generated scripts under scripts/ and determine the expected representation of multiple analyses, sensitivity analyses, and any renv setup before implementation. Done means the desired scope is agreed and the workflow generates valid specifications consistently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- json, python, r
- Domain
- analytics, data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100