BookmarkSubscribeRSS Feed
3 REPLIES 3
jimbarbour
Meteorite | Level 14
Ah. I see. But perhaps you could give us just a little bit more information on your data and exactly what it is that you are looking for. A sample of data and chart or table of the desired results would be most apt.

Jim
PGStats
Opal | Level 21

Define a format and associate it with your variables. You only need to specify the 'special' values, other values will adopt the default format.

 

proc format;
value ns
0 = "ns";
run;

data test;
array x{5};
do i = -5 to -1;
    do j = 1 to 5;
        x{j} = i + j;
        end;
    output;
    end;
format x1-x5 ns.;
drop i j;
run;

proc print data=test noobs; run;

image.png

PG

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 378 views
  • 1 like
  • 4 in conversation