Hi guys, I'm a new SAS programmer so I'm sorry if I ask you an easy question and I use SAS studio. I have a dataset made of 3 variables (qtr code id), I want obtain a dataset with id variable that contains every observations of the input dataset but repeated only once and a number of variables that correspond to the maximum frequency of the id in the input dataset. I ask you if there is a way to get this output with only one proc transpose and not by using two proc transpose and then merge the output. This is my code but it doesn't produce the desired output. data ex.data; input id qtr code $; datalines; 1 2 A 2 3 C 2 1 B 3 2 A 4 3 C 5 1 D 5 1 A 6 3 A ; run; proc transpose data=ex.data out=ex.out; by id; var qtr code; run; Thanks, Alessandro
... View more