Hi,
I’d like to draw a few 2d histograms in gray-scale, but draw others with the usual pretty palette. I know how to construct the gray-scale:
int ncol=10;
double red[ncol];
double green[ncol];
double blue[ncol];
double stops[ncol];
double dcol = 1/double(ncol);
double gray = 0;
for (int j = 0; j < ncol; j++) {
// ...... Define color with RGB equal to : gray, gray, gray .......
stops[j]=double(j)/double(ncol-1);
red[j]=gray;
blue[j]=gray;
green[j]=gray;
gray += dcol;
}
double totcol=50;
gStyle->CreateGradientColorTable(ncol, red,green,blue,stops,totcol);
But, I cannot figure out how to make it such that only specific histograms are drawn with the gray-scale. I wish to use the gray-scale histograms to show the active geometry of my detector as in the attached figure. Hits are placed in a TGraph and are drawn over the geometry. But, the program has other figures that should be displayed in color and I don’t think the two palettes can coexist… or can they?
mike kordosky