Learn R Programming

ddecompose (version 1.0.0)

aggregate_terms: Aggregate decomposition terms

Description

The function aggregates decomposition terms and calculates their covariance matrix based on detailed decomposition results.

Usage

aggregate_terms(
  x,
  aggregate_factors = TRUE,
  custom_aggregation = NULL,
  reweighting
)

Value

The function returns an updated object of class "ob_decompose" containing the aggregated decomposition terms.

Arguments

x

an object of class "ob_decompose", usually , a result of a call to [ob_decompose()].

aggregate_factors

boolean, if `TRUE` (default) terms associated with detailed factor levels are aggregated to a single term for every factor variable.

custom_aggregation

list specifying the aggregation of detailed decomposition terms. The parameter `custom_aggregation` overrides the parameter `aggregate_factors`. If `NULL` (default), then either all detailed terms or all terms associated with a single variable are returned.

reweighting

boolean, if `TRUE` the decompostion in `object` contains reweighting (i.e. specification and reweighting error)