Hi, I am pretty new to Stata and I am running a logistic regression.
I have followed some code I found in several sources and I was able to make a plot of the marginal effects of my independent variables on the predicted probability of my dependent variable be 1.
However, the plot labels for my independent variables are all messed up. Could someone help me please in setting this up? Bellow, I detail the case and attach the plot.
I have 25 independent variables (predictors). All of them are statistically significant. I wrote the following code (variable names and plot titles are in Portuguese):
logit NAO_DESISTENTE i.IN_AMOSTRA_ENEM i.PUBLICA i.IN_UNIVERSIDADE i.IN_LICENCIATURA i.IN_NOTURNO FEMININO ///
c.IDADE_INGRESSO i.PROGRAMA i.ENG_CIV i.ENG_ELE i.ENG_MEC i.ENG_QUI i.ENG_PRO i.ENG_AMB i.ENG_FLO i.ENG_OUT i.ARQUIT i.BIOLOG i.QUIMIC ///
i.MATEMA i.COMPUT i.TEC_INF i.TEC_IND, or
margins, dydx(*) asobserved
marginsplot, horizontal allxlabels recast(scatter) xline(0) title("Não desistência do curso, CTEM") xtitle("Efeito marginal sobre a probabilidade predita" "de não desistir do curso")
I obtained a good chart with plots for all my 25 predictors. But the labels are too big, are not aligned with the corresponding dots and I only got labels for 4 predictors. How to make the labels for the 25 predictors fit in the chart?

Thank you very much in advance,
Luiz
I have followed some code I found in several sources and I was able to make a plot of the marginal effects of my independent variables on the predicted probability of my dependent variable be 1.
However, the plot labels for my independent variables are all messed up. Could someone help me please in setting this up? Bellow, I detail the case and attach the plot.
I have 25 independent variables (predictors). All of them are statistically significant. I wrote the following code (variable names and plot titles are in Portuguese):
logit NAO_DESISTENTE i.IN_AMOSTRA_ENEM i.PUBLICA i.IN_UNIVERSIDADE i.IN_LICENCIATURA i.IN_NOTURNO FEMININO ///
c.IDADE_INGRESSO i.PROGRAMA i.ENG_CIV i.ENG_ELE i.ENG_MEC i.ENG_QUI i.ENG_PRO i.ENG_AMB i.ENG_FLO i.ENG_OUT i.ARQUIT i.BIOLOG i.QUIMIC ///
i.MATEMA i.COMPUT i.TEC_INF i.TEC_IND, or
margins, dydx(*) asobserved
marginsplot, horizontal allxlabels recast(scatter) xline(0) title("Não desistência do curso, CTEM") xtitle("Efeito marginal sobre a probabilidade predita" "de não desistir do curso")
I obtained a good chart with plots for all my 25 predictors. But the labels are too big, are not aligned with the corresponding dots and I only got labels for 4 predictors. How to make the labels for the 25 predictors fit in the chart?
Thank you very much in advance,
Luiz
Comment