Logo ROOT   6.12/06
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Namespaces
ratioplot5.py File Reference

Namespaces

 ratioplot5
 

Detailed Description

Example that shows how you can set the colors of the confidence interval bands by using the method TRatioPlot::SetConfidenceIntervalColors.

Inspired by the tutorial of Paul Gessinger.

pict1_ratioplot5.py.png
1 
2 import ROOT
3 
4 ROOT.gStyle.SetOptStat(0)
5 
6 c1 = ROOT.TCanvas("c1", "fit residual simple")
7 h1 = ROOT.TH1D("h1", "h1", 50, -5, 5)
8 h1.FillRandom("gaus", 2000)
9 h1.Fit("gaus")
10 h1.GetXaxis().SetTitle("x")
11 h1.GetYaxis().SetTitle("y")
12 
13 rp1 = ROOT.TRatioPlot(h1)
14 rp1.SetConfidenceIntervalColors(ROOT.kBlue, ROOT.kRed)
15 rp1.Draw()
16 c1.Update()
Author
Alberto Ferro

Definition in file ratioplot5.py.