Re: gStyle->SetErrorX(dx)

From: Alexander Mann <amann_at_uni-goettingen.de>
Date: Wed, 2 Jun 2010 10:23:34 +0200

Hi,

so what's wrong with this code then:

{

gStyle->SetErrorX(0.0);

h1 = new TH1F("h1", "h1", 2, -0.5, 1.5); h2 = new TH1F("h2", "h2", 2, -0.5, 1.5);

h1->Fill(0);
h2->Fill(0);
h2->Fill(0);
h2->Fill(1);

h = new TGraphAsymmErrors(h1, h2);

h->Draw("AL");

}

Does draw x error bars.

Is there a way to disable those without using an additional array?

cu,
Alexander

Am 02.06.2010 10:05, schrieb Olivier Couet:
> This setting dx=0 in gStyle->SetErrorX(dx) remove the errors bar display
> along X.
> As it is explain in the doc.
>
> -----Original Message-----
> From: owner-roottalk_at_root.cern.ch [mailto:owner-roottalk_at_root.cern.ch]
> On Behalf Of Alexander Mann
> Sent: Tuesday, June 01, 2010 7:38 PM
> To: roottalk_at_root.cern.ch
> Subject: [ROOT] gStyle->SetErrorX(dx)
>
> Hi,
>
> the documentation http://root.cern.ch/root/html/TGraphPainter.html says:
>
> "gStyle->SetErrorX(dx) controls the size of the error along x. dx = 0
> removes the error along x."
>
> Does this method to get rid of the x-error bars work?
>
> cu,
> Alexander
>
Received on Wed Jun 02 2010 - 10:23:32 CEST

This archive was generated by hypermail 2.2.0 : Wed Jun 02 2010 - 11:50:01 CEST