make_surv_methods: Create survival probabilities

make_surv_methodsR Documentation

Create survival probabilities

Description

These function are version of the survHE::make.surv() function from survHE. These are needed prior to blending.

Usage

make_surv(Surv, ...)

## S3 method for class 'survHE'
make_surv(Surv, t, nsim = 100, ...)

## S3 method for class 'flexsurvreg'
make_surv(Surv, t = NULL, nsim = 100, ...)

## S3 method for class 'inla'
make_surv(Surv, t = NULL, nsim = 100, ...)

## Default S3 method:
make_surv(Surv, t = NULL, nsim = 100, ...)

Arguments

Surv

survival analysis object

...

Additional arguments

t

Time points; vector

nsim

Number of simulations; integer

Value

Matrix of survival probabilities

Examples


library(survHE)

## trial data
data("TA174_FCR", package = "blendR")

## externally estimated data
data_sim <- ext_surv_sim(t_info = 144,
                         S_info = 0.05,
                         T_max = 180)

ext_Surv <- fit.models(formula = Surv(time, event) ~ 1,
                       data = data_sim,
                       distr = "exponential",
                       method = "hmc")

S_ext <- make_surv(ext_Surv, t = 1:100, nsim = 100)


blendR documentation built on Sept. 9, 2025, 5:51 p.m.