compute_dev_exp¶
- compute_dev_exp(BinData)¶
COMPUTE_DEV_EXP Compute proportional deviance explained by each model factor
- Usage:
[dev_exp_sta, dev_exp_sop] = compute_dev_exp(BinData)
- Inputs:
BinData : struct - all binned data required for the nested model fits – required
- Outputs:
dev_exp_sta : 1x3 double - deviance explained from [stage, phase, history] dev_exp_sop : 1x3 double - deviance explained from [SOP, phase, history]
Notes
Fits a sequence of nested Poisson GLMs (null, single-factor, and three-factor) via glmfit and computes the relative contribution of each factor to the total deviance reduction. Accompanies Chen et al., PNAS 2025 (https://doi.org/10.1073/pnas.2405276121).
See also: specify_mdl, build_design_mt, glmfit
∿∿∿ Prerau Laboratory MATLAB Codebase · sleepEEG.org ∿∿∿