Formats and prints a medsurv_fast object in the same layout as the
other two-group estimation summaries in the package. The header shows the
control label and the inference settings. The body shows the per-group
median survival with its confidence interval, followed, for a two-group
object, by the difference contrast (treatment minus control) with a
confidence interval, the test statistic, and the p-value.
The p-value column is labeled Pr(>|z|) for a two-sided test and
Pr(>z) for a one-sided test, whose p-value is the upper tail in the
direction of treatment benefit.
Arguments
- x
An object of class
"medsurv_fast"returned bymedsurv_fast.- digits
Number of significant digits to display. Defaults to the global option
getOption("digits").- ...
Additional arguments (currently unused).
Examples
set.seed(1)
time <- c(rexp(50, 0.1), rexp(50, 0.07))
status <- rep(1, 100)
group <- rep(c(0, 1), each = 50)
print(medsurv_fast(time, status, group, control = 0))
#> Median survival time (two-group)
#>
#> control = 0
#> method = km, alternative = two.sided
#>
#> median std.err lower 95% upper 95%
#> control 7.5861 1.3184 5.3961 10.6648
#> treatment 11.6279 1.9602 8.3561 16.1806
#>
#> Est. lower 95% upper 95% z Pr(>|z|)
#> difference (treatment - control) 4.0418 -0.5883 8.6720 1.711 0.0871 .
#> ---
#> Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
