Okay, another attempt (my apologies, I'm just trying to find a way to do this in SAS--need to do this for future projects, as the company only uses SAS :-P) Total of 9 columns: x1 to x9. Search through all the values of x1, row by row. If the value in row 9 is 0, then test_var in row 9 will be 0 and missing on the previous 8. Then, search through all the values of x2, x3, etc., row by row, conditioned on the fact that the corresponding row of x1 is NOT 0 AND the value of x2, x3, etc. is 0. Same idea as above, basically. I think you alluded that you can do this in SAS IML? I have access to that, too. Thanks!
... View more