Now, what I would like to do is taking the color of the Z axis and use them in other part of the code. My strategy in this moment is to pick up the palette and use GetValueColor:
auto* palette = dynamic_cast<TPaletteAxis*>(h_vals->GetListOfFunctions()->FindObject("palette"));
// first for main cell value histogram
double binc = h_vals->GetBinContent(get_bin_number(this_bin));
Int_t color_id = palette->GetValueColor(binc);
This does not work as expected, as you can see in the following plot example_Log.pdf (25.0 KB)
Do you have any suggestions on how to fix it or test the problem in a better way?