Hi, I'm using proc tabulate to create a table and I'm wondering if there's a way to select one level of a categorical variable to be printed, but keeping the % considering all the levels. See below the table that I have. I wanted the same table but to export in excel only the lines 'Yes' for the variable sick. See the code I have right now. Any other ideas are welcome. Thanks in advance! ods excel file="C:\ExampleTable1.xlsx" style=minimal;
proc tabulate data=ex;
class sick sex doctor location;
table (sex=' ')*(sick=' ' all), (location=' ' ALL)*(doctor=' ')*(n pctn<sick all>*f=10.1)/ nocellmerge printmiss misstext='0' box="Sick";
keylabel PctN="%" N="n" All="Total";
run;
ods excel close;
... View more