Dear all
I'm working in Stata 14.2.
I'm doing a two-level logit model with melogit. I'm interested in a cross-level interaction between the variable win (first level) and the variable camp (second level).
I think in this case, I have to take the first level variable in the random part of the model. Is this right?
Because win ist a factor variable i need the R. notation.
In the Stata manuals the .R notation ist normally used with the _all option. But this option takes all cluster together. I don't understand why this should makes sense.
So my question is what ist the difference between the following models? and which one should I take?
Code1
. melogit entscheid i.win##i.wissen i.win##i.prä i.win##i.Wirtschaft age i.educ i.sex i.lang i.win##c.camp || _all: R.win, cov(unstructured) intpoints(30)
Code2 with group identity variable
melogit entscheid i.win##i.wissen i.win##i.prä i.win##i.Wirtschaft i.win##ib2.zukunft age i.educ i.sex i.lang i.win##c.camp || idnr:R.win, covariance(unstructured) intpoints(30)
idnr ist the identifying variable.
And why is there only one var(_cons) in the output? Should not be there a variance for each category of win?
Related Posts with Multilevel crossed interaction for factor variable
ciplotI tried to use ciplot to plot two curves (var1 and var2) on the same graph. However, none of the mea…
Count frequencies of (binary) variable and merge these to original datasetThe following provides one solution to the problem. However, it seems unnecessarily complicated to m…
Descriptive Statistics by SegmentHi all, I have ratings data (ratings are 0-5) and I am trying to see what what % of users never rat…
Stochastic Frontier AnalysisI conducted Stochastic Frontier Analysis (SFA) using the command 'frontier' with the natural log of …
TWFE: Different results between Stata and RHi, We are running two-way fixed effects on R and Stata using the same data, and they are giving di…
Subscribe to:
Post Comments (Atom)
0 Response to Multilevel crossed interaction for factor variable
Post a Comment