Hello, I have a panel dataset with an ID variable and flags for certain missing values, missing values and real values. I would like to drop all individuals for wich VAR1 - VAR3 only contain either a 4 or a missing value (so rows 3 & 4 in the example data), but no other values. I cannot figure out how to do this properly.


Code:
clear
input ID VAR1 VAR2 VAR3
1 . 4 2
2 100 4 .
3 . . 4 
4 . 4 . 
5 3 . 4 
6 1 1 4 
end