The palette seems to be ignored in option "col"

Hello,

I have a tree in a file called tmp.root, and I would like to plot some variables with option “col”, using a specified palette. Here is what I do:

$ root -l tmp.root root [0] Attaching file tmp.root as _file0... root [1] gStyle->SetPalette(1) root [2] tiff.Draw("ypix:xpix:val", "", "colz") <TCanvas::MakeDefCanvas>: created default TCanvas with name c1 (Long64_t)111940

The palette is completely ignored. I get the same result without the “SetPalette(1)”.

This used to work with previous versions of ROOT. I now am using:

* Version 5.15/07 25 April 2007 *

Am I doing anything wrong?

Thanks

Pierre-François Giraud

Hi Pierre-François,

After you change the style for objects you read from .root files (if they are saved there with a different style), you may use the following:gStyle->SetPalette(1); gROOT>ForceStyle(); ...Cheers, Ilka

Hi Ilka,

No this doesn’t work…

Are you able to reproduce the problem?

Pierre-François

1 Like

Hi Pierre-François,

I cannot reproduce the problem. It works for me and using gROOT->ForceStyle() I can change the palette in the same ROOT session. What is your environment?

Cheers, Ilka