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

proc tabulate data = demog missing;

class trt gender race;

var age;

table age = 'Age' *(n = 'n' * f = 8.mean = 'Mean' * f = 5.1

std = 'Standard Deviation' * f = 5.1

min = 'Min' * f = 3. Max = 'Max' * f = 3.)

gender = 'Gender' *

(n='n' * f = 3. colpctn = '%' * f = 4.1)

race = 'Race' *

(n = 'n' * f = 3. colpctn = '%' * f = 4.1),

(trt = " ") (all = 'Overall');

format trt trt. race race. gender gender.;

title1 'Table 5.1';

title2 'Demographics and Baseline Characteristics';

footnote1 "* Other includes Asian, Native American, and other"

" races.";

footnote2 "Created by %sysfunc(getoption(sysin)) on"

" &sysdate9..";

run;

In this code, what is the meaning of 'f'? Is it freq?

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

Format - what format to apply to the display of the measure in the tabulate table.

View solution in original post

4 REPLIES 4
Reeza
Super User

Format - what format to apply to the display of the measure in the tabulate table.

cecily
Calcite | Level 5

Thank you

ballardw
Super User

I have never figured out why SAS programmed proc tabulate to display n or nmiss , which are counts, with 2 decimals by default.

Cynthia_sas
Diamond | Level 26

Hi: In SAS 9.4, my TABULATE does not use decimal places for N or NMISS when I take all the defaults. I am not sure when this changed.

cynthia

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

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.

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 4 replies
  • 3727 views
  • 0 likes
  • 4 in conversation