(I know I should know this). I want to get rid of the hard coded number (10021). This number equals the number of records in the data set.
My objective is to count the number of obs in each efaprimary category listed in the WHERE clause and then get a percentage that it represents of the entire data set. In other words, there are some efaprimary codes not included in the report but I need to count those obs to use in the denominator.
proc sql; SELECT d.efaprimary, count(efaprimary) as Ncount, calculated Ncount/10021 as Pct format=percent8.2 FROM d45 as d WHERE enroll_status='0' and grade_level not in ('-1','-2') and efaprimary in ('*DD','*OHI','*PMD','*TBI','AU','EH','EM','HH','LD','OH','SP','TM','VH') GROUP BY efaprimary; QUIT;
... View more