Hi,
I am trying to convert a variable that has 5 options into a binary variable where every value >=1 equals 1 and every value 0 = 0. This is what I am entering in currently but I seem to be unable to group the 0 dummy correctly.
In the attatched picture I have written replace GRB=1 if GradeRepeat >=2 but also entering replace GRB=1 if GradeRepeat >=1 produces the same outcome. Incorrect grouping and it is using the total observations not solely the observations from GradeRepeat (8,984 instead of desired 5,943).
Thanks in advance for any help, I am a Stata beginner.
EDIT: I have sent a message to the Mods/Admins to correct my username.
I am trying to convert a variable that has 5 options into a binary variable where every value >=1 equals 1 and every value 0 = 0. This is what I am entering in currently but I seem to be unable to group the 0 dummy correctly.
In the attatched picture I have written replace GRB=1 if GradeRepeat >=2 but also entering replace GRB=1 if GradeRepeat >=1 produces the same outcome. Incorrect grouping and it is using the total observations not solely the observations from GradeRepeat (8,984 instead of desired 5,943).
Thanks in advance for any help, I am a Stata beginner.
EDIT: I have sent a message to the Mods/Admins to correct my username.
Comment