Skip to content

Implement (cause-specific) competing risks#782

Draft
jemus42 wants to merge 3 commits into
imbs-hl:masterfrom
jemus42:comprisk
Draft

Implement (cause-specific) competing risks#782
jemus42 wants to merge 3 commits into
imbs-hl:masterfrom
jemus42:comprisk

Conversation

@jemus42

@jemus42 jemus42 commented Feb 28, 2026

Copy link
Copy Markdown
Contributor

Just an experiment to see how it goes when I point Claude Code at it 🤷🏻‍♂️

jemus42 and others added 3 commits February 28, 2026 02:10
Extend survival forests to handle competing risks data where the status
variable encodes censoring (0) or one of K event types (1, 2, ..., K).
Uses composite sum of squared log-rank statistics across event types for
splitting, following Ishwaran et al. (2014). Returns cause-specific CHFs
as a list of K matrices and cumulative incidence functions (CIF) via the
Aalen-Johansen estimator. Fully backward compatible when K=1.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- R/utility.R: prob -> probs in quantile() call
- test_interface.R: dependent.variable -> dependent.variable.name
- test_ranger.R: $prediction -> $predictions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Update roxygen docs for ranger() and predict.ranger() with competing
  risks parameters, return values, and examples
- Add Ishwaran et al. (2014) reference for cause-specific hazard approach
- Add vignettes/competing_risks.Rmd with method description and usage
- Add inst/examples/competing_risks_comparison.R (ranger vs rfsrc)
- Add knitr/rmarkdown to Suggests and VignetteBuilder to DESCRIPTION

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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