util_reduce_replicates: Reduce replicated simulation results to one value per metric

View source: R/util_stuff.R

util_reduce_replicatesR Documentation

Reduce replicated simulation results to one value per metric

Description

Aggregate simulation results over measured ticks and over replicates

Usage

util_reduce_replicates(results, cols)

Arguments

results

tibble of simulation results, as returned by run_nl_one()

cols

character vector of metric columns that should be reduced

Details

Reduction happens in two stages: first the mean over all measured ticks within each replicate, then the mean over the replicates. Replicates are identified by the random-seed column. The two stages matter whenever replicates return a different number of ticks (for example when an exit condition is defined), because a single mean over all rows would weight long runs higher than short ones.

Value

tibble with one row and one column per entry of cols


nlrx documentation built on Nov. 25, 2026, 5:09 p.m.