Change axis label density inTH1

Consider this example:

TCanvas *c =	new TCanvas;
TH1 * h = new TH1F("h", "h", 5, 0.0, 1.0);
h ->	Draw();

How can I change the label density for the axes? E.g. for the y axis make the labels more sparse - only 0.0, 0.5 and 1.0?

Please read tips for efficient and successful posting and posting code

ROOT Version: Not Provided
Platform: Not Provided
Compiler: Not Provided

Seet TAxis::SetNdivisions()

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.