Well, WHITE is a color, but I guess you are saying you want a non-white color for the missing cells.
I assume your current program looks like the following. Notice that I am using the HEATMAPPARM statement, which assumes the data are presummarized:
data Have;
input ID Diet Day;
datalines;
1 0 0
1 0 2
1 1 3
2 1 1
3 0 1
4 1 0
5 0 2
5 2 3
;
title "A Heat Map";
proc sgplot data=Have;
heatmapparm x=Day y=ID colorgroup=Diet;
run;
To add color to the missing cells, you need to explicitly add the coordinates of the cells and use a missing value for the DIET variable. THe following code creates a grid of missing values and then merges the data with the grid so that your observed values overwrite the missing values:
/* create grid of missing values */
data Missing;
do ID = 1 to 5;
do Day = 0 to 3;
Diet = .;
output;
end;
end;
run;
/* merge with observed data */
data Combine;
merge Missing Have;
by ID Day;
run;
/* for consistent results, you might want to sort by the response var */
proc sort data=Combine;
by Diet;
run;
title "A Heat Map";
proc sgplot data=Combine;
heatmapparm x=Day y=ID colorgroup=Diet / outline;
keylegend;
run;
The color of the missing cells is the GraphMissing style element in the current ODS style.
... View more