Hello all, I'm very new to stata and I'm using the software for a class project. I've created a dummy variable that is supposed to be returning "1" when my probit model correctly predicts the outcome of whether an NFL team makes the playoffs or not. The following is my code:
gen correct_p = 0
replace correct_p=1 if playoff==1 & playoff_probit>=.5
replace correct_p=1 if playoff==0 & playoff_probit<.5
sum correct_p
The issue I'm having is that when the conditions for the replace command are met, no 1 is being returned. It states "0 Real Changes Made". I can't seem to figure out why this is happening, because when I look into my code, the conditions for the replace command are met in most instances and the command should be returning a 1 in those instances. I would appreciate any help.
gen correct_p = 0
replace correct_p=1 if playoff==1 & playoff_probit>=.5
replace correct_p=1 if playoff==0 & playoff_probit<.5
sum correct_p
The issue I'm having is that when the conditions for the replace command are met, no 1 is being returned. It states "0 Real Changes Made". I can't seem to figure out why this is happening, because when I look into my code, the conditions for the replace command are met in most instances and the command should be returning a 1 in those instances. I would appreciate any help.
Comment