get_surv_draws: Posterior draws of survival

View source: R/accessors.R

get_surv_drawsR Documentation

Posterior draws of survival

Description

Accepts either a predict_survival_curves() result (static survival on a temperature × duration grid) or a predict_heat_injury() result (dynamic survival along a temperature trace). In the heat-injury case requires save_draws = TRUE.

Usage

get_surv_draws(x)

Arguments

x

A list returned by predict_survival_curves() or by predict_heat_injury().

Value

A long-format tibble. For predict_survival_curves(): .draw, temp, duration, survival. For predict_heat_injury(): .draw, time, temp, survival. For a grouped fit the moderator column(s) are also carried (so per-group draws are not collapsed).

Examples

## Not run: 
psc <- predict_survival_curves(wf, temps = c(32, 34),
                               durations = c(0.5, 1))
get_surv_draws(psc)

hi <- predict_heat_injury(trace, wf, save_draws = TRUE)
get_surv_draws(hi)

## End(Not run)

bayesTLS documentation built on Nov. 29, 2026, 1:06 a.m.