aggregate_stats: Aggregate Statistics ACROSS ID

View source: R/core_stats.R

aggregate_statsR Documentation

Aggregate Statistics ACROSS ID

Description

aggregate_stats is a (not exported) generic function to aggregate stats_dm objects across IDs. Since the column names may vary by the statistic type, the behavior of aggregate depends on the subclass of stats_dm (cafs, quantiles, delta_funs, or fit_stats).

Usage

aggregate_stats(stat_df)

## S3 method for class 'cafs'
aggregate_stats(stat_df)

## S3 method for class 'quantiles'
aggregate_stats(stat_df)

## S3 method for class 'delta_funs'
aggregate_stats(stat_df)

## S3 method for class 'fit_stats'
aggregate_stats(stat_df)

Arguments

stat_df

A data.frame of class stats_dm

Details

For each supported subclass, aggregate_stats calls internal_aggregate() with the relevant arguments

Value

If no "ID" column exists in stat_df returns stat_df as-is. If an "ID" column exists, then statistics are aggregated across it.

See Also

new_stats_dm, calc_stats, internal_aggregate()


dRiftDM documentation built on April 3, 2025, 7:48 p.m.