Skip to contents

Title

Usage

trial_init(trial = NULL, prob = 0.25, as_ts = FALSE)

Arguments

trial

Examples

bernoulli_trial() |>
trial_init()
#>   history t1_outcome t1_prob
#> 1       1          0    0.75
#> 2       2          1    0.25

bernoulli_trial() |>
trial_init(as_ts = TRUE)
#> # A tibble: 2 × 4
#>   history trial outcome  prob
#>     <int> <chr>   <dbl> <dbl>
#> 1       1 t1          0  0.75
#> 2       2 t1          1  0.25

trial_init() -> hi