*Hi, This is the lesson and there are two solutions below. In the first solution please let me know if you need .... count+1? both solutions are the same without it. If it is included, what is the reasoning. Thank you!! ********************************************************; * LESSON 2, PRACTICE 1 *; * a) Open the PG2.NP_YEARLYTRAFFIC table. Notice the *; * Count column records the number of cars that have *; * passed through a particular Location. *; * b) Modify the DATA step to create a column, totTraffic,*; * that is the running total of Count. *; * b) Keep the ParkName, Location, Count, and *; * totTraffic columns in the output table. *; * c) Format totTraffic so values are displayed with *; * commas. *; ***********************************************************; data totalTraffic ; set pg2.np_yearlyTraffic; Count+1; *Running Total of Count */; retain totTraffic 0; totTraffic+Count; format totTraffic comma12.; keep ParkName Location Count totTraffic; run; /*OR*/ data totalTraffic; set pg2.np_yearlytraffic; totTraffic+Count; keep ParkName Location Count totTraffic; format totTraffic comma12.; run;
... View more