Hello, I am new to the SAS community and am getting started with learning. I have a set of great books and especially like The Little SAS Book and its companion, 'Exercises and Projects for The Little SAS Book' I am looking for solution for Chapter 3 Programming exercise 33 f : Create another cumulative counter variable that tracks the number of wins for each team. I already used retain statement but it didn't work. data sol33; infile 'G:\Exercise\RoseBowl.dat' ; input game_date mmddyy10. team $22. @38 score 2. @41 lost_team $22. lost_score ; diff=score-lost_score; game_day=weekday(game_date); counter+1; retain pre_team; output; pre_team=team; if pre_team =team then win_count+1; run;
... View more