BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
zhuxiaoyan1
Quartz | Level 8

I have this data:

Epi_fin_year Wave Epi_type_Key Count_distinct_of_Epi_Nbr Sum_of_Sum_of_Total_Allowed  Avg_Allowed_Epi Avg_Year

2012 W1 1 885 19198732.91 21693.483515 21702.068486
2012 W1 2 78 762181.486 9771.5575129 9876.4201282
2012 W1 3 2811 28183124.654 10026.013751 10033.622031
2013 W1 1 659 13896550.679 21087.330317 21488.154127
2013 W1 2 70 696002.45887 9942.8922696 10319.539857
2013 W1 3 2536 25425294.309 10025.746967 10584.89636
2013 W2A 4 9264 15511448.11 1674.3791138 1677.8677386
2013 W2A 5 1606 7459184.3186 4644.5730502 4645.7133313
2013 W2A 6 670 1589169.6556 2371.8950084 2373.9683582
2014 W1 1 862 18286857.393 21214.451732 21660.289165
2014 W1 2 67 611344.69164 9124.5476365 9253.4059701
2014 W1 3 2858 28682968.119 10036.028033 10417.551442
2014 W2A 4 8430 14060389.575 1667.8991192 1652.5151056
2014 W2A 5 1368 6435436.9996 4704.2668126 4835.6508406
2014 W2A 6 409 972627.76467 2378.0629943 2788.7380929
2014 W2B 7 748 11651724.737 15577.172108 15591.970963
2014 W2B 8 170 7871341.5104 46302.008885 46302.481176
2014 W2B 9 1267 1754282.7806 1384.5957226 1384.887577
2014 W2B 10 296 1199982.1687 4053.9938133 4053.6361149
2015 W1 1 822 17594292.354 21404.248606 22263.572324
2015 W1 2 66 689807.99666 10451.636313 10317.628333
2015 W1 3 2690 26831991.929 9974.7181891 10546.950691
2015 W2A 4 8052 13374303.234 1660.9914598 1646.7500832
2015 W2A 5 1278 5844651.9261 4573.2800674 4784.7674491
2015 W2A 6 465 1094501.7615 2353.767229 2981.3035699
2015 W2B 7 608 9131883.7446 15019.545633 15637.881743
2015 W2B 8 142 6791152.4671 47825.017374 48567.695352
2015 W2B 9 1097 1509527.9951 1376.0510438 1555.6936645
2015 W2B 10 334 1238947.2857 3709.423011 3930.4265269

I wrote this code ofr the sas data set attached and got the fowwing results (part of them):

proc tabulate data=Epi_Avg;

class epi_type_key epi_fin_year;

var 'count distinct_of_epi_nbr'n Avg_Allowed_EPI Avg_Year;

table epi_type_key, ('count distinct_of_epi_nbr'n="Episode Count" Avg_Allowed_EPI="Avg. Allowed of Each Code"

Avg_Year="Avg. Allowed of Overall"), epi_fin_year="Overall";

run;

 

 

Overall

2012

2013

2014

2015

Episode Count

Sum

885.00

659.00

862.00

822.00

Avg. Allowed of Each Code

Sum

21693.48

21087.33

21214.45

21404.25

Avg. Allowed of Overall

Sum

21702.07

21488.15

21660.29

22263.57

 

_
    
    
    

 

    
    
    

 

How do I get rid off the column "Sum" ? Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Cynthia_sas
SAS Super FREQ

Hi, you need to do 2 things:
1) add the statement
keylabel sum = ' ';
(that is quote-space-quote after the = sign)
2) change the TABLE statement at the very end, where you have
, epi_fin_year="Overall";
change it to:
, epi_fin_year="Overall" / row=float;

cynthia

View solution in original post

1 REPLY 1
Cynthia_sas
SAS Super FREQ

Hi, you need to do 2 things:
1) add the statement
keylabel sum = ' ';
(that is quote-space-quote after the = sign)
2) change the TABLE statement at the very end, where you have
, epi_fin_year="Overall";
change it to:
, epi_fin_year="Overall" / row=float;

cynthia

sas-innovate-2024.png

Today is the last day to save with the early bird rate! Register today for just $695 - $100 off the standard rate.

 

Plus, pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 594 views
  • 0 likes
  • 2 in conversation