Power planning for Cox survival studies
A Cox proportional hazards design needs more than a hazard ratio. It needs enough observed events. This calculator helps estimate that planning point. It follows the Schoenfeld style approximation used for binary exposure comparisons. The method links power to events, allocation, alpha level, and the expected log hazard ratio.
Why event information matters
Survival studies often enroll many people, yet only events create most model information. A larger cohort can still have weak power when events are rare. For that reason, the tool reports required events and then converts them into sample size. It uses the average event probability across groups. It also reduces usable events for dropout. This makes the answer easier to review before collection starts.
Inputs that shape the result
The hazard ratio is the main effect measure. Values below one suggest lower hazard in the exposed group. Values above one suggest higher hazard. Allocation ratio controls the split between groups. Balanced allocation usually gives efficient information. Unequal allocation may be needed for cost or recruitment limits. The alpha field sets the type one error level. The sided test option changes the critical value. The covariate R squared field adjusts for correlation with other predictors. A larger value increases the event requirement.
How to read the output
Power mode starts with total sample size. It estimates expected events and the resulting power. Required events mode starts with desired power. It returns the number of events and approximate sample size. Detectable hazard ratio mode starts with sample size and desired power. It reports the smallest effect away from one that the design can detect.
Using results with Stata
The generated command note is a planning aid. It keeps your main assumptions visible. You can compare it with your final survival dataset and modeling plan. Always check proportional hazards, censoring patterns, and clinical plausibility. These calculations are approximate. They are useful for design screening, sensitivity checks, and discussion. Final protocols may need simulation, competing risk review, or advice from a statistician.
Sensitivity checks
Run several scenarios before choosing a design. Change the hazard ratio, dropout, and event rates. Small changes can shift required events sharply. Save exports for protocol tables and reviewer notes.