Dear Stata experts,
I'm trying to test several GLM models. I have two independent variables (X and Y). X is binary and Y is continuous. The dependent variable (Z) is binary. I also have two moderators (M and N).
According to my understanding, if I only have one independent variable (X), the models are like this:
Model 1 (Empty model): Z = M + N + control variables
Model 2 (Main effect): Z = X + M + N + control variables
Model 3 (Moderating effect M): Z = X + X*M + control variables
Model 4 (Moderating effect N): Z = X + X*N + control variables
Model 5 (Full model): Z = X + X*M + X*N + control variables
Now since I have two IVs X and Y, and I want to test the moderating effects of M and N on both X and Y. How should I add Y, Y*M, and Y*N in the models? Should I just repeat Model 1 through Model 5 by replacing X with Y? Or should I put X and Y together in the five models?
Thank you very much for helping!
Related Posts with How to fit GLM models with two independent variables and two moderators?
"Not sorted"Dear All, I have individual level panel data that includes spells, with a 6 month *follow up* period…
Log transforming variablesTwo questions related to log transforming variables. I understand that we would want to log transfo…
initial values not feasible melogitHello -- I am running an melogit on a 330,000 person nested in ~1900 neighborhoods in 47 countries. …
Comparing two datasets by two variablesHi, I am very new to stata. I have x1, y1, z variables in data1.dta and x2, y2, N in data2.dta. I a…
power analysis for modified poisson regressionHello, I am trying to determine the power of one my analyses. The outcome is binary and relative ri…
Subscribe to:
Post Comments (Atom)
0 Response to How to fit GLM models with two independent variables and two moderators?
Post a Comment