SAS collapse dates
问题 I have a dataset which looks like this: cust date 1 2 3... 600 1 1 5 . . ... . 1 2 5 . . ... . 1 2 . 4 . ... . 1 2 . . 6 ... . 2 1 1 . . ... . 2 1 . 5 . ... . 2 2 . . . ... 10 I want to collapse variables 1 to 600 for each date by customer (cust), so that the dataset looks like this: cust date 1 2 3... 600 1 1 5 . . ... . 1 2 5 4 6 ... . 2 1 1 5 . ... . 2 2 . . . ... 10 I started with the following code (maybe it's a bit complicated), and it doesn't work: data want ; set have; array vars