initialize_comparison: Start a sequential comparison

View source: R/comparison.R

initialize_comparisonR Documentation

Start a sequential comparison

Description

Creates the state object that update_comparison() advances one instance at a time. Nothing is observed yet; the confidence sequence is ⁠[a, b]⁠, the full range of the paired difference.

Usage

initialize_comparison(design)

Arguments

design

A comparison_design().

Value

An object of class seqbench_comparison. Its main components are design, data (all rows seen so far), trajectory (one row per instance: estimate, confidence sequence, running intersection, cost and decision at that time), decision, stopping_reason, diagnostics and meta (versions, timestamps). Use tidy() for the trajectory, glance() for a one-row summary and comparison_report() for the full contract.

Examples

design <- comparison_design(margin = 0.02, bounds = c(0, 1))
state <- initialize_comparison(design)
state

seqbench documentation built on Oct. 8, 2026, 5:07 p.m.