You can use this code:
data myData;
set myData;
array a(*) _numeric_;
do i=1 to dim(a);
if a(i) = . then a(i) = 0;
end;
drop i;
run;
Or you can just run all the steps and add this at the bottom of your datastep:
array a(*) _numeric_;
do i=1 to dim(a);
if a(i) = . then a(i) = 0;
end;
drop i; .
BTW this will replace the . to zeros, the "." represents a missing value in SAS, you can replace the 0 on the code that I provided for any other value you want to show instead of .
EDIT:given your inputs the code should be like this:
PROC SORT DATA=ABC
OUT=ABC1 ;
BY EMP;
RUN;
PROC TRANSPOSE DATA=ABC1 OUT=ABC2 NAME=Source LABEL=Label;
BY EM;
ID VC;
VAR FQ;
/* ------------------------------------------------------------------- End of task code. ------------------------------------------------------------------- /
RUN; QUIT;
/* Start of custom user code. */
data ABC2;
set ABC2;
array a(*) _numeric_;
do i=1 to dim(a);
if a(i) = . then a(i) = 0;
end;
drop i;
run;