prepare_test() attaches a test specification to a <def_var> object,
producing a test_lazy ready for optional recalibration with via()
before being executed with conclude().
Arguments
- .x
An S7 object extension yielded by, e.g.
<def_var>object fromdefine_model(), or an<expanded_model>object fromwrite_models().- .test
A test function such as TTEST that carries
<test_spec>objects when called.- ...
Additional arguments passed to methods.
Examples
sleep |>
define_model(x_by(extra, group)) |>
prepare_test(TTEST) |>
conclude()
#>
#> == Model =======================================================================
#>
#> Variable Mapper : x_by
#> Args : extra | group
#> x_vars : 1
#> by_vars : 1
#>
#> == T-Test ======================================================================
#>
#> -- Summary ---------------------------------------------------------------------
#>
#> ──────────────────────────────────────────
#> group estimate t_stat df p_val
#> ──────────────────────────────────────────
#> group -1.580 -1.861 17.780 0.079
#> ──────────────────────────────────────────
#>
#>
#> -- Confidence Interval ---------------------------------------------------------
#>
#> ─────────────────────────────
#> group lower_95 upper_95
#> ─────────────────────────────
#> group -3.365 0.206
#> ─────────────────────────────
#>
#>