
Reconstruct the adjusted-model main-effect terms for a MAIHDA decomposition
Source:R/decompose_maihda.R
maihda_adjusted_terms.RdFor each stratum-defining variable, returns the model term to add as an additive
fixed main effect in the adjusted model, plus the data augmented with any
reconstructed binned factors. A categorical dimension is used directly; a numeric
dimension that make_strata tertile-binned is reconstructed as the
same binned factor (using the stored breaks/labels), because
make_strata() bins only a temporary copy and leaves the original numeric
column intact – adding the raw numeric column would wrongly enter a linear term
instead of the factor that defines the strata.