
Summarize and Rename Coefficients for an ITS Model
summary_its.RdThis function takes a gls model object generated by `fit_its_model()`
and modifies the summary output by renaming the coefficients, variable names, and other model-related terms
to make them easier to interpret in the context of interrupted time series (ITS) analysis.
Value
A modified summary of the gls model object, where the coefficient names and other relevant
model attributes have been renamed to be more interpretable.
Details
The function modifies various components of the gls object, including:
Coefficients
Variable names in matrices (e.g., variance-covariance)
Terms and factors used in the model
Predicted variables
The renamed terms in the model output are specifically tailored to better describe the parameters of ITS models, such as control and pilot group slopes before and after interventions.
The function provides more meaningful names for ITS models by replacing default coefficient names with:
(Intercept)becomes "Control y-axis intercept"xbecomes "Pilot y-axis intercept difference to control"time_indexbecomes "Control pre-intervention slope"x:time_indexbecomes "Pilot pre-intervention slope difference to control"
Additional terms for up to 3 interventions are automatically renamed, reflecting intervention-related slopes in both control and pilot groups.