BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hello experts-
In my dataset, I have a simple variable with 4 values of 1,2,3,4. While there will never be missing data, often not all values will appear in the actual data. However, I would like all values to appear in the report column, with a 0 freq count showing in the cell.

How can I force all this? Here is the define statement I am using:

define eval / across order=freq descending format=evaltyp.
center width=30 spacing=4 left "Evaluation Result";

Thanks !
Francine
College of American Pathologists
2 REPLIES 2
Cynthia_sas
Diamond | Level 26
Hi:
Assuming that your user-defined format has all the values, then you probably just need to add the PRELOADFMT option to your DEFINE statement:

[pre]
define eval / across order=freq descending format=evaltyp. preloadfmt
center width=30 spacing=4 left "Evaluation Result";
[/pre]

You'd also need to have [pre]
OPTIONS MISSING=0;
PROC REPORT ....;
RUN;
[/pre]

or else you'll get a . for the missing.

cynthia
deleted_user
Not applicable
Cynthia,
thank you very much. This is a perfect fix for my problem.

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
  • 2 replies
  • 952 views
  • 0 likes
  • 2 in conversation