tidy.surv: Extract tidy estimates from survinger objects

tidy.survR Documentation

Extract tidy estimates from survinger objects

Description

Converts survinger result objects into tidy tibbles suitable for further analysis with dplyr, ggplot2, or other tidyverse tools.

Usage

## S3 method for class 'surv_prevalence'
tidy(x, ...)

## S3 method for class 'surv_nowcast'
tidy(x, ...)

## S3 method for class 'surv_adjusted'
tidy(x, ...)

## S3 method for class 'surv_allocation'
tidy(x, ...)

## S3 method for class 'surv_delay_fit'
tidy(x, ...)

Arguments

x

A survinger result object.

...

Additional arguments (currently unused).

Value

A tibble.

Examples

sim <- surv_simulate(n_regions = 3, n_weeks = 10, seed = 1)
d <- surv_design(sim$sequences, ~ region,
                 sim$population[c("region", "seq_rate")], sim$population)
prev <- surv_lineage_prevalence(d, "BA.2.86")
tidy(prev)

survinger documentation built on April 27, 2026, 9:10 a.m.