I am trying to figure out how to correctly estimate confidence intervals for random effects after estimating a mixed model using the "mixed" command.
Suppose I have a mixed model of the form:
and that this model returns coefficient estimates b_iv and b_0 in its fixed component.
I understand (I think) from Stata's documentation and previous posts in this forum that, after this command, the following will be true:
will create a variable b_iv_random that gives the estimated "slope" for iv at each value of i, minus the "fixed effect" for iv (b_iv). In other words, b_iv_random gives a kind of deviation from the fixed effect, and will always average to about 0.
That is, if "i" were a variable to index subjects, I could create a variable with to capture subject-specific slopes with
My question concerns how to estimate appropriate 95% confidence intervals for these subject-specific slopes (or, more generally, slopes specific to any given level of i).
Would it be simply:
Or do I need to do something to explicitly incorporate the standard error of the fixed effect, b_iv?
I ask because it took me some time to learn (I hope correctly) that Stata's subject-specific slope estimate is b_iv+b_iv_random, not simply b_iv_random, and I would hate to wrongly assume that the subject-specific *standard error* for that slope is b_iv_rese. But at the same time, it seems unlikely that it is, say, b_iv_rese + [the standard error for b_iv].
In case I am asking the wrong question, some context:
I have conducted an experiment with two fixed factors and one random factor, all randomly manipulated across subjects.
I have estimated a mixed model of the form
I would like to be able to report the estimated effects of each fixed iv (and their interaction, their conditional marginal effects, etc.) at each level of random_iv and to conclude, for example, that the effect of fixed_iv1 ranged from [smaller number] to [larger number] and was significant and positive across all levels of random_iv when when fixed_iv2=1.
This seems to me a helpful thing to do for people who (like me) may have difficulty interpreting Stata's variance estimate for the random effects parameter for fixed_iv1. Particularly given that the CI for that variance estimate will never include 0, so I can't very well do a "significance" test of that parameter. But am I missing some other obvious, helpful way of reporting how coefficients vary across levels in a mixed model? Is there, for example, an analog for "estat icc" that quantifies this?
Suppose I have a mixed model of the form:
Code:
mixed dv iv || i: iv
I understand (I think) from Stata's documentation and previous posts in this forum that, after this command, the following will be true:
Code:
predict b_iv_random, reffects
That is, if "i" were a variable to index subjects, I could create a variable with to capture subject-specific slopes with
Code:
gen b_i = b_iv + b_iv_random
Would it be simply:
Code:
predict b_iv_rese, reses gen b_i_cilo = b_iv+b_iv_random-2*b_iv_rese gen b_i_cihi = b_iv+b_iv_random+2*b_iv_rese
I ask because it took me some time to learn (I hope correctly) that Stata's subject-specific slope estimate is b_iv+b_iv_random, not simply b_iv_random, and I would hate to wrongly assume that the subject-specific *standard error* for that slope is b_iv_rese. But at the same time, it seems unlikely that it is, say, b_iv_rese + [the standard error for b_iv].
In case I am asking the wrong question, some context:
I have conducted an experiment with two fixed factors and one random factor, all randomly manipulated across subjects.
I have estimated a mixed model of the form
Code:
mixed dv i.fixed_iv1##i.fixed_iv2 || random_iv: i.fixed_iv1##i.fixed_iv2
This seems to me a helpful thing to do for people who (like me) may have difficulty interpreting Stata's variance estimate for the random effects parameter for fixed_iv1. Particularly given that the CI for that variance estimate will never include 0, so I can't very well do a "significance" test of that parameter. But am I missing some other obvious, helpful way of reporting how coefficients vary across levels in a mixed model? Is there, for example, an analog for "estat icc" that quantifies this?
Comment