gStyle->SetErrorX(dx) works for histogram. Here you draw a
TGraphAsymmErrors.
gStyle->SetErrorX(dx) as no effect on TGraphAsymmErrors.
If one use TGraphAsymmErrors it is assume it is to the errors.
The graph without errors is TGraph.
-----Original Message-----
From: Alexander Mann [mailto:amann_at_uni-goettingen.de]
Sent: Wednesday, June 02, 2010 10:24 AM
To: Olivier Couet
Cc: roottalk_at_root.cern.ch
Subject: Re: [ROOT] gStyle->SetErrorX(dx)
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:27:13 CEST
This archive was generated by hypermail 2.2.0 : Wed Jun 02 2010 - 11:50:01 CEST