Learn R Programming

heemod (version 0.9.0)

pool: Pool Two or More Survival Distributions

Description

Pool a set of survival distributions using the specified weights.

Usage

pool(..., weights = 1)

pool_(dots, weights = 1)

Arguments

...
Survival distributions to be used in the projection.
weights
A vector of weights used in pooling.
dots
Used to work around non-standard evaluation.

Value

A surv_pooled object.

Examples

Run this code

dist1 <- define_survival(distribution = "exp", rate = .5)
dist2 <- define_survival(distribution = "gompertz", rate = .5, shape = 1)
pooled_dist <- pool(dist1, dist2, weights = c(0.25, 0.75))

Run the code above in your browser using DataLab