Hi all,

I have data on several individuals and their workplace, collected over a number of years (say, five). The companies participating in this study are the same in each wave, but the people change. Before the last wave, an intervention was carried out which makes me hypothesise that one of the person-level variables, say x_1, should now be more strongly correlated with the outcome variable y.

Given these premises, my approach would by to run a three-level model with people nested in companies nested in years and add a ‘random’ slope of the form `(1 + x1 | year)`

. The idea is, even if the variance is small and the fit compared to `(1 | year)`

does not improve, if it is possible to recover the posterior distribution of these deviation w_1 to w_5 from \beta_1 (the global average for the variable of interest x_1) I should be able to carry out statistical tests of difference from the mean / median of the coefficient for last wave compared to previous waves, or to use simulations to see if the last wave’s posterior is different from the earlier ones.

Does this make sense and would it work? Are there any other approaches that you would recommend?

Thank you,

k.