Hi all,
I'm using a probit model to estimate long term credit ratings and incountering difficulty getting an estimated credit rating in my output.
I've attached my code below.
Problems I'm having are;
- Why does th model only recognize the number of the variable sdlticrs (#1 #2.. ..#6) and not the ratings themselves (1 2 3 … 16)?;
- Why is the model only recognizing 8 ratings while there are 16?;
- In my output the code adds estimator columns (column AU till FB). I’m not sure how to interpret these. I want it to generate 1 column with 1 expected credit rating for each sic2id.
Hopefully somebody can help me with these issues.
Looking forward to your reply.
I'm using a probit model to estimate long term credit ratings and incountering difficulty getting an estimated credit rating in my output.
I've attached my code below.
Problems I'm having are;
- Why does th model only recognize the number of the variable sdlticrs (#1 #2.. ..#6) and not the ratings themselves (1 2 3 … 16)?;
- Why is the model only recognizing 8 ratings while there are 16?;
- In my output the code adds estimator columns (column AU till FB). I’m not sure how to interpret these. I want it to generate 1 column with 1 expected credit rating for each sic2id.
Hopefully somebody can help me with these issues.
Looking forward to your reply.
Code:
sum sic2id scalar max2=r(max) local k=max2 set more off forvalues i=1(1)`k'{ qui oprobit sdlticrs sizebysale profit rd sga i.rdind tang mtb if sic2id==`i' eststo oprobit foreach o in #1 #2 #3 #4 #5 #6 { qui margins, pr (outcome(`o')) post eststo, title(Outcome `o') estimates restore oprobit } eststo drop oprobit esttab using probit.csv, se nostar mtitles nonumbers nobase title(Predicted long term credit rating `i') append obslast di `i' " / " `k' }
Comment