BookmarkSubscribeRSS Feed
Sasnoob
Calcite | Level 5

Having trouble getting this to work. I need the computed field and the other analysis fields to follow underneath the column variable

proc report data=data;

column  row1 row2  column1, (var1 var2 computevar);

define row1/ group  ;

define row2/ group  ;

define column1/ across ;

define var1/ analysis sum ;

define var2/ analysis sum ;

define computevar/ computed;

compute computevar;

computevar = var1.sum/var2.sum;

endcomp;

run;

Any ideas ?

1 REPLY 1
Cynthia_sas
Diamond | Level 26

Hi:

  I believe that if you search the forum for previous postings, you will find many (really, a LOT) of previous postings with code....including one just last week on the same topic. You will want to search on some of these strings:

REPORT ACROSS ABSOLUTE COLUMN NUMBERS or just

REPORT ACROSS calculate.

cynthia

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

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