Hi everyone, I have a quick question on how to delete observations. Say I have a data set as following: data example; input y x1 x2 x3 x4 x5; cards; 5 1 2 3 . 5 2 4 . . 6 8 ; run; I want to delete rest of the observations after the first encounter of a missing value. For example I want the following result. 5 1 2 3 . . 2 4 . . . . What would the code look like? I tried using do loop with delete statement but it didn't quite work. I tried array x{5} x1 x2 x3 x4 x5; do i=1 to 5; if x=. then delete x to x[5]; output; end; Any help would be appreciated. Thanks!
... View more