In proc report, how do i get the '.' value to be displayed as 'unknown', rather than the missing indicator (see table below). For character variables i could simply change all missing values to 'unknown' in the dataset, but i cannot do that with numerical vars.
Hi,
Use PROC FORMAT before proc report, then apply created format in proc report to display the missing value as 'unknown'.
If you're already using a SAS supplied format like percent. below sample code to demonstrate how you can extend it for a missing case.
proc format;
value missToUnknown
. = 'Unknown'
other=[percent.]
;
run;
data demo;
do var=-0.5,.,0,0.5;
output;
end;
run;
proc print data=demo;
format var missToUnknown.;
run;
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
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.
Ready to level-up your skills? Choose your own adventure.