So the endogenous statement in proc qlim is to specify that dependent variable on the left hand side of the equation is endogenous;
proc qlim data = mydata itprint; title "enrolled logit regression model results"; class race gender; model curr_enrolled = age race gender; endogenous curr_enrolled ~ discrete (distribution = logit); output out =logit marginal proball; run;
The ENDOGENOUS statement in PROC QLIM is for specifying the type of dependent variables that appear on the left-hand side of the equation. In other words, endogenous variables listed after each ENDOGENOUS statement refer to the dependent variables that appear on the left-hand side of the equation. You can also use the options of the MODEL statement to achieve the same result. For example, in the SAS code you wrote, you may as well accomplish the same results by the commands below:
proc qlim data = mydata itprint;
title "enrolled logit regression model results";
class race gender;
model curr_enrolled = age race gender / discrete (distribution = logit);
output out =logit marginal proball;
Note that if you have the endogeneity problem in your model, that is, if one or more of your regressors are correlated with your model errors, the ENDOGENOUS statement is not how you can take into account this problem in your estimations. In the case of endogeneity, you should estimate your model of interest (the structural equation) and the reduced form equation(s) simultaneously. Of course, to be able to do this, you need to find proper instruments to form your reduced form model(s). To see if you have endogeneity of not, you can use the ENDOTEST option of the MODEL statement. For more information please see the Endogeneity and Instrumental Variables subsection of the PROC QLIM documentation.
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.