Compute Shapley values for the longitudinal causal decomposition
Source:R/causal_shapley.R
causal_shapley.RdComputes the average decomposition across all 6 possible orderings of the three component types (behavioral, compositional, pretreatment). Since orderings are paired (between-group and within-group use the same structural ordering), there are exactly 6 evaluations.
Value
An object of class "ineqx_causal_longit" with
order = "shapley" and additional fields:
- shapley
data.frame with Shapley-averaged values for each component at each time period
- all_orderings
List of 6
ineqx_causal_longitresults, one per ordering- ranges
data.frame showing min/max for each component across orderings