I am new to STATA.
I know how to run logistic regressions individually and to predict values and residuals. I want to know how I can do this in a for loop.
If I have a y-variable and multiple x-variables, how can I run multiple Logistic regressions and predict the values and residuals. Specifically, how can I do the following in a loop:
logit y-variable x-variable1
predict values1
predict residuals1, res
logit y-variable x-variable1 x-variable2
predict values2
predict residuals2, res
logit y-variable x-variable1 x-variable2 x-variable3
predict values3
predict residuals3, res
logit y-variable x-variable1 x-variable2 x-variable3 x-variable4
predict values4
predict residuals4, res
Related Posts with For loop for running multiple regressions in Stata
why I need to run the command keep twice to delete some observations? Code: ---------------------------------------------------------------------------------------------…
Analysis of Demographic Factors Across SyllabiHi all! I'm very new to Stata so apologies in advance if my question isn't very well formed. I am p…
Reverse Causality and Panel DataHi all, I hope all is well. Please, I am studying if some of the variables affect firm instrument is…
Panel regression model / Multiple regression model?Hi everyone, I have a dataset available which links the the Covid-19 situation to the change in por…
Table1_mc stata 16 issueHello, I am trying to create a table 1 in stata 16. I am using the following code: table1_mc, by(r…
Subscribe to:
Post Comments (Atom)
0 Response to For loop for running multiple regressions in Stata
Post a Comment