ROOT 6.13/01 Reference Guide |
Public Member Functions | |
TSPlot () | |
default constructor (used by I/O only) More... | |
TSPlot (Int_t nx, Int_t ny, Int_t ne, Int_t ns, TTree *tree) | |
virtual | ~TSPlot () |
destructor More... | |
void | Browse (TBrowser *b) |
To browse the histograms. More... | |
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,... More... | |
void | FillXvarHists (Int_t nbins=100) |
Fills the histograms of x variables (not weighted) with nbins. More... | |
void | FillYpdfHists (Int_t nbins=100) |
Fills the histograms of pdf-s of y variables with binning nbins. More... | |
void | FillYvarHists (Int_t nbins=100) |
Fill the histograms of y variables. More... | |
Int_t | GetNevents () |
Int_t | GetNspecies () |
void | GetSWeights (TMatrixD &weights) |
Returns the matrix of sweights. More... | |
void | GetSWeights (Double_t *weights) |
Returns the matrix of sweights. It is assumed that the array passed in the argurment is big enough. More... | |
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, they are filled with default binning 50 If parameter ixvar!=-1, the histogram of x-variable #ixvar is returned for species ispecies If parameter ixvar==-1, the histogram of y-variable #iyexcl is returned for species ispecies If the histogram has already been filled and the binning is different from the parameter nbins all histograms with old binning will be deleted and refilled. More... | |
TObjArray * | GetSWeightsHists () |
Returns an array of all histograms of variables, weighted with sWeights If histograms have not been already filled, they are filled with default binning 50 The order of histograms in the array: x0_species0, x0_species1,..., x1_species0, x1_species1,..., y0_species0, y0_species1,... More... | |
TString * | GetTreeExpression () |
TString * | GetTreeName () |
TString * | GetTreeSelection () |
TH1D * | GetXvarHist (Int_t ixvar) |
Returns the histogram of variable #ixvar If histograms have not already been filled, they are filled with default binning 100. More... | |
TObjArray * | GetXvarHists () |
Returns the array of histograms of x variables (not weighted) If histograms have not already been filled, they are filled with default binning 100. More... | |
TH1D * | GetYpdfHist (Int_t iyvar, Int_t ispecies) |
Returns the histogram of the pdf of variable #iyvar for species #ispecies, binning nbins If histograms have not already been filled, they are filled with default binning 100. More... | |
TObjArray * | GetYpdfHists () |
Returns the array of histograms of pdf's of y variables with binning nbins If histograms have not already been filled, they are filled with default binning 100. More... | |
TH1D * | GetYvarHist (Int_t iyvar) |
Returns the histogram of variable iyvar.If histograms have not already been filled, they are filled with default binning 100. More... | |
TObjArray * | GetYvarHists () |
Returns the array of histograms of y variables. More... | |
Bool_t | IsFolder () const |
void | MakeSPlot (Option_t *option="v") |
Calculates the sWeights The option controls the print level "Q" - no print out "V" - prints the estimated #of events in species - default "VV" - as "V" + the minuit printing + sums of weights for control. More... | |
void | RefillHist (Int_t type, Int_t var, Int_t nbins, Double_t min, Double_t max, Int_t nspecies=-1) |
The Fill...Hist() methods fill the histograms with the real limits on the variables This method allows to refill the specified histogram with user-set boundaries min and max Parameters: type = 1 - histogram of x variable #nvar = 2 - histogram of y variable #nvar = 3 - histogram of y_pdf for y #nvar and species #nspecies = 4 - histogram of x variable #nvar, species #nspecies, WITH sWeights = 5 - histogram of y variable #nvar, species #nspecies, WITH sWeights. More... | |
void | SetInitialNumbersOfSpecies (Int_t *numbers) |
Set the initial number of events of each species - used as initial estimates in minuit. More... | |
void | SetNEvents (Int_t ne) |
void | SetNSpecies (Int_t ns) |
void | SetNX (Int_t nx) |
void | SetNY (Int_t ny) |
void | SetTree (TTree *tree) |
Set the input Tree. More... | |
void | SetTreeSelection (const char *varexp="", const char *selection="", Long64_t firstentry=0) |
Specifies the variables from the tree to be used for splot. More... | |
Protected Member Functions | |
void | SPlots (Double_t *covmat, Int_t i_excl) |
Computes the sWeights from the covariance matrix. More... | |
Protected Attributes | |
TMatrixD | fMinmax |
Int_t | fNevents |
Int_t | fNSpecies |
Double_t * | fNumbersOfEvents |
Int_t | fNx |
Int_t | fNy |
TMatrixD | fPdfTot |
TString * | fSelection |
TMatrixD | fSWeights |
TObjArray | fSWeightsHists |
TTree * | fTree |
TString * | fTreename |
TString * | fVarexp |
TMatrixD | fXvar |
TObjArray | fXvarHists |
TMatrixD | fYpdf |
TObjArray | fYpdfHists |
TMatrixD | fYvar |
TObjArray | fYvarHists |
#include <TSPlot.h>
TSPlot::TSPlot | ( | ) |
default constructor (used by I/O only)
Definition at line 433 of file TSPlot.cxx.
TSPlot::TSPlot | ( | Int_t | nx, |
Int_t | ny, | ||
Int_t | ne, | ||
Int_t | ns, | ||
TTree * | tree | ||
) |
Definition at line 448 of file TSPlot.cxx.
|
virtual |
destructor
Definition at line 477 of file TSPlot.cxx.
void TSPlot::Browse | ( | TBrowser * | b | ) |
To browse the histograms.
Definition at line 492 of file TSPlot.cxx.
void TSPlot::FillSWeightsHists | ( | Int_t | nbins = 50 | ) |
The order of histograms in the array: x0_species0, x0_species1,..., x1_species0, x1_species1,..., y0_species0, y0_species1,...
If the histograms have already been filled with a different binning, they are refilled and all histograms are deleted
Definition at line 833 of file TSPlot.cxx.
void TSPlot::FillXvarHists | ( | Int_t | nbins = 100 | ) |
Fills the histograms of x variables (not weighted) with nbins.
Definition at line 665 of file TSPlot.cxx.
void TSPlot::FillYpdfHists | ( | Int_t | nbins = 100 | ) |
Fills the histograms of pdf-s of y variables with binning nbins.
Definition at line 775 of file TSPlot.cxx.
void TSPlot::FillYvarHists | ( | Int_t | nbins = 100 | ) |
Fill the histograms of y variables.
Definition at line 722 of file TSPlot.cxx.
void TSPlot::GetSWeights | ( | TMatrixD & | weights | ) |
Returns the matrix of sweights.
Definition at line 643 of file TSPlot.cxx.
void TSPlot::GetSWeights | ( | Double_t * | weights | ) |
Returns the matrix of sweights. It is assumed that the array passed in the argurment is big enough.
Definition at line 653 of file TSPlot.cxx.
TH1D * TSPlot::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, they are filled with default binning 50 If parameter ixvar!=-1, the histogram of x-variable #ixvar is returned for species ispecies If parameter ixvar==-1, the histogram of y-variable #iyexcl is returned for species ispecies If the histogram has already been filled and the binning is different from the parameter nbins all histograms with old binning will be deleted and refilled.
Definition at line 964 of file TSPlot.cxx.
TObjArray * TSPlot::GetSWeightsHists | ( | ) |
Returns an array of all histograms of variables, weighted with sWeights If histograms have not been already filled, they are filled with default binning 50 The order of histograms in the array: x0_species0, x0_species1,..., x1_species0, x1_species1,..., y0_species0, y0_species1,...
Definition at line 880 of file TSPlot.cxx.
TH1D * TSPlot::GetXvarHist | ( | Int_t | ixvar | ) |
Returns the histogram of variable #ixvar If histograms have not already been filled, they are filled with default binning 100.
Definition at line 708 of file TSPlot.cxx.
TObjArray * TSPlot::GetXvarHists | ( | ) |
Returns the array of histograms of x variables (not weighted) If histograms have not already been filled, they are filled with default binning 100.
Definition at line 693 of file TSPlot.cxx.
TH1D * TSPlot::GetYpdfHist | ( | Int_t | iyvar, |
Int_t | ispecies | ||
) |
Returns the histogram of the pdf of variable #iyvar for species #ispecies, binning nbins If histograms have not already been filled, they are filled with default binning 100.
Definition at line 818 of file TSPlot.cxx.
TObjArray * TSPlot::GetYpdfHists | ( | ) |
Returns the array of histograms of pdf's of y variables with binning nbins If histograms have not already been filled, they are filled with default binning 100.
Definition at line 804 of file TSPlot.cxx.
TH1D * TSPlot::GetYvarHist | ( | Int_t | iyvar | ) |
Returns the histogram of variable iyvar.If histograms have not already been filled, they are filled with default binning 100.
Definition at line 762 of file TSPlot.cxx.
TObjArray * TSPlot::GetYvarHists | ( | ) |
Returns the array of histograms of y variables.
If histograms have not already been filled, they are filled with default binning 100.
Definition at line 748 of file TSPlot.cxx.
void TSPlot::MakeSPlot | ( | Option_t * | option = "v" | ) |
Calculates the sWeights The option controls the print level "Q" - no print out "V" - prints the estimated #of events in species - default "VV" - as "V" + the minuit printing + sums of weights for control.
Definition at line 542 of file TSPlot.cxx.
void TSPlot::RefillHist | ( | Int_t | type, |
Int_t | var, | ||
Int_t | nbins, | ||
Double_t | min, | ||
Double_t | max, | ||
Int_t | nspecies = -1 |
||
) |
The Fill...Hist() methods fill the histograms with the real limits on the variables This method allows to refill the specified histogram with user-set boundaries min and max Parameters: type = 1 - histogram of x variable #nvar = 2 - histogram of y variable #nvar = 3 - histogram of y_pdf for y #nvar and species #nspecies = 4 - histogram of x variable #nvar, species #nspecies, WITH sWeights = 5 - histogram of y variable #nvar, species #nspecies, WITH sWeights.
Definition at line 899 of file TSPlot.cxx.
void TSPlot::SetInitialNumbersOfSpecies | ( | Int_t * | numbers | ) |
Set the initial number of events of each species - used as initial estimates in minuit.
Definition at line 527 of file TSPlot.cxx.
void TSPlot::SetTree | ( | TTree * | tree | ) |
Set the input Tree.
Definition at line 982 of file TSPlot.cxx.
void TSPlot::SetTreeSelection | ( | const char * | varexp = "" , |
const char * | selection = "" , |
||
Long64_t | firstentry = 0 |
||
) |
Specifies the variables from the tree to be used for splot.
Variables fNx, fNy, fNSpecies and fNEvents should already be set!
In the 1st parameter it is assumed that first fNx variables are x(control variables), then fNy y variables (discriminating variables), then fNy*fNSpecies ypdf variables (probability distribution functions of dicriminating variables for different species). The order of pdfs should be: species0_y0, species0_y1,... species1_y0, species1_y1,...species[fNSpecies-1]_y0... The 2nd parameter allows to make a cut TTree::Draw method description contains more details on specifying expression and selection
Definition at line 1000 of file TSPlot.cxx.
|
protected |
Computes the sWeights from the covariance matrix.
Definition at line 622 of file TSPlot.cxx.