42 TTree *datatree =
new TTree(
"datatree",
"datatree");
43 datatree->ReadFile(dataFile,
44 "Mes/D:dE/D:F/D:MesSignal/D:MesBackground/D:dESignal/D:dEBackground/D:FSignal/D:FBackground/D",
' ');
55 "Mes:dE:F:MesSignal:dESignal:FSignal:MesBackground:" 56 "dEBackground:FBackground");
61 ne[0]=500; ne[1]=5000;
84 "sPlots of Mes and F signal and background", 800, 600);
91 pt->
AddText(
"sPlots of Mes and F signal and background,");
92 pt->
AddText(
"obtained by the tutorial TestSPlot.C on BABAR MC " 93 "data (sPlot_toyMC.fit)");
95 "M. Pivk and F. R. Le Diberder, Nucl.Inst.Meth.A, physics/0402083");
100 TPad* pad1 =
new TPad(
"pad1",
"Mes signal",0.02,0.43,0.48,0.83,33);
101 TPad* pad2 =
new TPad(
"pad2",
"Mes background",0.5,0.43,0.98,0.83,33);
102 TPad* pad3 =
new TPad(
"pad3",
"F signal", 0.02, 0.02, 0.48, 0.41,33);
103 TPad* pad4 =
new TPad(
"pad4",
"F background", 0.5, 0.02, 0.98, 0.41,33);
114 sweight00->
Draw(
"e");
126 sweight10->
SetTitle(
"Mes background");
128 sweight10->
Draw(
"e");
142 sweight02->
Draw(
"e");
154 sweight12->
SetTitle(
"F background");
156 sweight12->
Draw(
"e");
virtual void Draw(Option_t *option="")
Draw this pavetext with its current attributes.
void SetInitialNumbersOfSpecies(Int_t *numbers)
Set the initial number of events of each species - used as initial estimates in minuit.
void MakeSPlot(Option_t *option="v")
Calculates the sWeights The option controls the print level "Q" - no print out "V" - prints the estim...
TString & ReplaceAll(const TString &s1, const TString &s2)
TVirtualPad * cd(Int_t subpadnumber=0)
Set current canvas & pad.
virtual TText * AddText(Double_t x1, Double_t y1, const char *label)
Add a new Text line to this pavetext at given coordinates.
virtual void SetLabelOffset(Float_t offset=0.005)
Set distance between the axis and the labels The distance is expressed in per cent of the pad width...
virtual const char * UnixPathName(const char *unixpathname)
Convert from a Unix pathname to a local pathname.
virtual void SetTextFont(Font_t tfont=62)
Set the text font.
TVirtualPad * cd(Int_t subpadnumber=0)
Set Current pad.
virtual void SetGrid(Int_t valuex=1, Int_t valuey=1)
virtual void SetMarkerColor(Color_t mcolor=1)
Set the marker color.
Base class for several text objects.
virtual void Draw(Option_t *option="")
Draw Pad in Current pad (re-parent pad if necessary).
virtual void SetLineColor(Color_t lcolor)
Set the line color.
R__EXTERN TSystem * gSystem
virtual void Draw(Option_t *option="")
Draw this histogram with options.
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
The most important graphics class in the ROOT system.
char * Form(const char *fmt,...)
virtual void SetMarkerStyle(Style_t mstyle=1)
Set the marker style.
tomato 1-D histogram with a double per channel (see TH1 documentation)}
virtual void SetLabelSize(Float_t size=0.04)
Set size of axis labels The size is expressed in per cent of the pad width.
virtual void SetMarkerSize(Size_t msize=1)
Set the marker size.
A Pave (see TPave) with text, lines or/and boxes inside.
void SetTreeSelection(const char *varexp="", const char *selection="", Long64_t firstentry=0)
Specifies the variables from the tree to be used for splot.
virtual void SetTextColor(Color_t tcolor=1)
Set the text color.
A TTree object has a header with a name and a title.
virtual void SetTitle(const char *title)
Change (i.e.
virtual void SetStats(Bool_t stats=kTRUE)
Set statistics option on/off.
void FillSWeightsHists(Int_t nbins=50)
The order of histograms in the array: x0_species0, x0_species1,..., x1_species0, x1_species1,..., y0_species0, y0_species1,...
TH1D * GetSWeightsHist(Int_t ixvar, Int_t ispecies, Int_t iyexcl=-1)
Returns the histogram of a variable, weithed with sWeights If histograms have not been already filled...
const char * Data() const