Re: RangeAxis

Rene Brun (Rene.Brun@cern.ch)
Fri, 21 Feb 1997 12:26:25 +0100


Thomas Kraemerkaemper wrote:
>
> the workaround did also not work. This is my macro:
>
> {
> TCanvas *canvas = new TCanvas("canvas", "My Canvas",0,0,800,600);
> canvas->Divide(2, 1, 0.01, 0.0, 0);
> TLine diagonal(0., 0., 60., 60.);
> TH2F hPtFrame("hPtFrame", "", 60, 0, 60, 60, 0, 60);
>
> canvas_1->cd();
> hPtFrame.Draw();
> ntuple.Draw("JetPt0:PartonEt0", "", "boxsame");
> diagonal.Draw("same");
> canvas_2->cd();
> hPtFrame.Draw();
> ntuple.Draw("uPartonEt0:PartonEt0", "", "boxsame");
> diagonal.Draw("same");
> canvas->Update();
> }
>
> The result shows only empty histograms with the diagonal
> line. Moreover, if I leave out the 'box' option in the first
> 'ntuple.Draw', then the second one is drawn! It is drawn not only in
> the range of the histogram, but also outside.
>
> There seems to be another problem with box plots: Low (but
> homogeneous) density regions of a scatter plot are shown as rows and
> columns of small boxes in each eightth bin and nothing between
> these. I have tried to provide you a postscript example, but the small
> boxes nearly vanish in the postscript output.
>
> Tsch"uss, Thomas Kr"amerk"amper.

I have simplified your macro to amke it working:
{
TCanvas *canvas = new TCanvas("canvas","My Canvas",0,0,800,600);
canvas->Divide(2, 1, 0.01, 0.0, 0);
TLine diagonal(0., 0., 60., 60.);
TH2F hPtFrame("hPtFrame", "", 60, 0, 60, 60, 0, 60);

canvas_1->cd();
ntuple.Draw("JetPt0:PartonEt0>>hPtFrame", "", "box");
diagonal.Draw();
canvas_2->cd();
ntuple.Draw("uPartonEt0:PartonEt0>>hPtFrame", "", "box");
diagonal.Draw();
}

Rene Brun