I have data such as
and wish to make data such as:
where WANT equals to the SMALLEST value of 'score' greater than 0 for each 'student' and if all student scores equals to 0 then it sets to missing.
Code:
input student score 1 1 1 0 1 2 2 0 2 6 2 7 3 9 3 2 3 0 4 0 4 0 4 0
Code:
input student score WANT 1 1 1 1 0 1 1 2 1 2 0 6 2 6 6 2 7 6 3 9 2 3 2 2 3 0 2 4 0 . 4 0 . 4 0 .
Comment