Design a rigorous causal inference study using the target trial framework.
Estimate the effect of a treatment or exposure from observational, non-randomized data.
Generate transparent R code for matching, standardization, or IP weighting analyses.
Check and report how well an emulated trial holds up using synthetic teaching data.
| jacobjameson/tte_cc | hadley/logger | yulab-smu/cast3d | |
|---|---|---|---|
| Stars | 0 | 1 | 2 |
| Language | R | R | R |
| Last pushed | — | 2024-10-16 | — |
| Maintenance | — | Stale | — |
| Setup difficulty | moderate | easy | easy |
| Complexity | 4/5 | 2/5 | 2/5 |
| Audience | researcher | developer | researcher |
Figures from each repo's GitHub metadata at analysis time.
Running the R engine directly requires installing several R packages like survival and MatchIt.
TTE_CC is a toolkit for a statistics method called target trial emulation, packaged as a set of Claude Code skills plus a small R helper library. Target trial emulation is a way of estimating whether something like a treatment or vaccine actually causes an effect, using real world observational data rather than a randomized experiment, by first carefully defining what a hypothetical randomized trial would have looked like, then recreating that trial as closely as possible with the data on hand. The skills are built to be interactive and opinionated. Instead of just running numbers, they interview the user about their study design and push back on common mistakes, like comparing people who already started treatment, poorly defined treatment strategies, or a mismatched starting point for follow-up. The idea is that a trustworthy answer depends on first asking a well-defined question. The project follows a published academic framework for this kind of analysis and is modeled on how it is taught at Harvard, though it is an independent, unaffiliated project with its own entirely made-up teaching data rather than any real course materials. The toolkit is organized around two steps: first specifying the causal question through an eight-part protocol covering things like eligibility, treatment strategies, and follow-up, then emulating that trial with appropriate statistical methods and honestly reporting how well the emulation held up. Individual skills cover specifying the trial, aligning the starting point correctly, handling competing events like death, choosing an emulation method, handling long-term sustained treatment strategies, generating the actual R analysis code, and checking or reporting results. Underneath the skills sits an R engine with functions for building risk curves, matching, standardization, weighting, and bootstrapped confidence intervals, plus fully synthetic example datasets describing a fictional vaccine so every example can run immediately without needing real patient data. Installing it is a single terminal command that downloads the toolkit and links the skills into Claude Code, after which commands like /target-trial become available. Using the R engine directly requires installing several R packages such as survival, MatchIt, and ggplot2.
A set of Claude Code skills and an R toolkit that walk you through target trial emulation, a rigorous way to estimate cause and effect from observational data.
Mainly R. The stack also includes R, Claude Code, Bash.
No license information is provided in the README.
Setup difficulty is rated moderate, with roughly 30min to a first successful run.
Mainly researcher.
This repo across BitVibe Labs
Verify against the repo before relying on details.