Hi everyone
We are investigating the relationship between women's education and contraceptive use in India. We are making splines for educational level and we have used the following code in stata:
We are looking at both current use end ever use of contraception methods and the graph we obtain is presented here. We are a bit surprised about the results, the use contraceptive use is higher than we expected.
So our questions is:
Would this be the right way to get the predicted probability from a logistic regression?


We are investigating the relationship between women's education and contraceptive use in India. We are making splines for educational level and we have used the following code in stata:
Code:
mkspline edu1 5 edu2 8 edu3 12 edu4 = education logistic everused edu1-edu4 age age2 dontknow_caste middle_caste high_caste muslim christian other poorer middle richer richest, robust adjust age age2 dontknow_caste middle_caste high_caste muslim christian other middle poorer richer richest, gen(pr1) generate expr1=exp(pr1) generate prob1=1/(1+expr1) logistic currentmethod edu1-edu4 age age2 dontknow_caste middle_caste high_caste muslim christian other poorer middle richer richest, robust adjust age age2 dontknow_caste middle_caste high_caste muslim christian other middle poorer richer richest, gen(pr2) generate expr2=exp(pr2) generate prob2=1/(1+expr2)
So our questions is:
Would this be the right way to get the predicted probability from a logistic regression?
Comment