87 fAxisList->SetOwner();
88 fAxisLabelList->SetOwner();
91 fDistributionSize=nBins;
93 fBinFactorConstant=1.0;
100 if(startWithRootNode) {
101 return GetRootNode()->UpdateFirstLastBin(
kFALSE);
106 fFirstBin=GetPrevNode()->GetEndBin();
107 }
else if(GetParentNode()) {
110 fFirstBin=GetParentNode()->GetStartBin()+
111 GetParentNode()->GetDistributionNumberOfBins();
119 if((!GetChildNode())&&(GetDistributionDimension()==1)&&
120 (fHasUnderflow==1)) {
124 fLastBin=fFirstBin+fDistributionSize;
127 fLastBin=node->UpdateFirstLastBin(
kFALSE);
134 :
TNamed(name ? name :
"",name ? name :
"")
142 TString nameString(binNames);
143 delete fAxisLabelList;
144 fAxisLabelList=nameString.Tokenize(
";");
146 UpdateFirstLastBin();
158 AddAxis(axis,includeUnderflow,includeOverflow);
159 UpdateFirstLastBin();
165 if(childNode)
delete childNode;
167 if(GetParentNode() && (GetParentNode()->GetChildNode()==
this)) {
168 parentNode->childNode=nextNode;
170 if(GetPrevNode()) prevNode->nextNode=nextNode;
171 if(GetNextNode()) nextNode->prevNode=prevNode;
173 delete fAxisLabelList;
177 (
const char *name,
Int_t nBins,
const char *binNames)
194 Error(
"binning \"%s\" already has parent \"%s\", can not be added to %s",
199 Error(
"binning \"%s\" has previous node \"%s\", can not be added to %s",
204 Error(
"binning \"%s\" has next node \"%s\", can not be added to %s",
223 UpdateFirstLastBin();
243 Fatal(
"AddAxis",
"number of bins %d is not positive",
247 Fatal(
"AddAxis",
"xmin=%f required to be smaller than xmax=%f",
253 for(
Int_t i=0;i<=nBin;i++) {
254 binBorders[i]=x+i*dx;
256 r=AddAxis(name,nBin,binBorders,hasUnderflow,hasOverflow);
257 delete [] binBorders;
274 for(
Int_t i=0;i<nBin;i++) {
278 Bool_t r=AddAxis(axis.
GetTitle(),nBin,binBorders,hasUnderflow,hasOverflow);
279 delete [] binBorders;
294 if(HasUnconnectedBins()) {
295 Fatal(
"AddAxis",
"node already has %d bins without axis",
296 GetDistributionNumberOfBins());
298 Fatal(
"AddAxis",
"number of bins %d is not positive",
303 for(
Int_t i=0;i<=nBin;i++) {
304 (*bins)(i)=binBorders[i];
306 Fatal(
"AddAxis",
"bin border %d is not finite",i);
308 }
else if((i>0)&&((*bins)(i)<=(*bins)(i-1))) {
309 Fatal(
"AddAxis",
"bins not in order x[%d]=%f <= %f=x[%d]",
310 i,(*bins)(i),(*bins)(i-1),i-1);
315 Int_t axis=fAxisList->GetEntriesFast();
316 Int_t bitMask=1<<axis;
319 fHasUnderflow |= bitMask;
322 fHasUnderflow &= ~bitMask;
325 fHasOverflow |= bitMask;
328 fHasOverflow &= ~bitMask;
330 fAxisList->AddLast(bins);
331 fAxisLabelList->AddLast(
new TObjString(name));
332 if(!fDistributionSize) fDistributionSize=1;
333 fDistributionSize *= nBinUO;
334 UpdateFirstLastBin();
346 out<<
"TUnfoldBinning \""<<
GetName()<<
"\" has ";
347 Int_t nBin=GetEndBin()-GetStartBin();
354 <<GetStartBin()<<
","<<GetEndBin()<<
"] nTH1x=" 355 <<GetTH1xNumberOfBins()
357 if(GetDistributionNumberOfBins()) {
359 out<<
" distribution: "<<GetDistributionNumberOfBins()<<
" bins\n";
360 if(fAxisList->GetEntriesFast()) {
363 for(
Int_t axis=0;axis<GetDistributionDimension();axis++) {
366 <<GetDistributionAxisLabel(axis)
367 <<
"\" nbin="<<GetDistributionBinning(axis)->GetNrows()-1;
368 if(fHasUnderflow & (1<<axis)) out<<
" plus underflow";
369 if(fHasOverflow & (1<<axis)) out<<
" plus overflow";
377 for(
Int_t ibin=0;(ibin<GetDistributionNumberOfBins())&&
378 (ibin<fAxisLabelList->GetEntriesFast());ibin++) {
380 if(GetDistributionAxisLabel(ibin)) {
381 out<<GetDistributionAxisLabel(ibin);
403 if((!name)||(!TString(
GetName()).CompareTo(name))) {
432 (
const char *histogramName,
const char *histogramTitle,
Int_t const *axisList)
449 for(iEnd=2;iEnd>0;iEnd--) {
450 if(axisList[iEnd]>=0)
break;
452 for(
Int_t i=0;i<=iEnd;i++) {
457 r += GetNonemptyNode()->GetDistributionAxisLabel(axisList[i]);
465 (
const char *histogramName,
const char *histogramTitle,
483 }
else if(xAxis>=0) {
484 r += GetNonemptyNode()->GetDistributionAxisLabel(xAxis);
489 }
else if(yAxis>=0) {
498 (
Bool_t originalAxisBinning,
const char *axisSteering)
const 515 Int_t axisBins[3],axisList[3];
516 GetTHxxBinning(originalAxisBinning ? 1 : 0,axisBins,axisList,
522 (
const char *histogramName,
Bool_t originalAxisBinning,
Int_t **binMap,
523 const char *histogramTitle,
const char *axisSteering)
const 549 Int_t nBin[3],axisList[3];
550 Int_t nDim=GetTHxxBinning(originalAxisBinning ? 3 : 0,nBin,axisList,
553 TString title=BuildHistogramTitle(histogramName,histogramTitle,axisList);
564 r=
new TH3D(histogramName,title,
569 r=
new TH2D(histogramName,title,
577 if(originalAxisBinning) {
579 "Original binning can not be represented as THxx");
581 r=
new TH1D(histogramName,title,nBin[0],0.5,nBin[0]+0.5);
585 *binMap=CreateBinMap(r,nDim,axisList,axisSteering);
591 (
const char *histogramName,
Bool_t originalAxisBinning,
Int_t **binMap,
592 const char *histogramTitle,
const char *axisSteering)
const 618 Int_t nBin[3],axisList[3];
619 Int_t nDim=GetTHxxBinning(originalAxisBinning ? 1 : 0,nBin,axisList,
621 TString title=BuildHistogramTitle(histogramName,histogramTitle,axisList);
625 GetNonemptyNode()->fAxisList->At(axisList[0]);
629 if(originalAxisBinning) {
630 Info(
"CreateErrorMatrixHistogram",
631 "Original binning can not be represented on one axis");
633 r=
new TH2D(histogramName,title,nBin[0],0.5,nBin[0]+0.5,
634 nBin[0],0.5,nBin[0]+0.5);
638 *binMap=CreateBinMap(r,nDim,axisList,axisSteering);
645 char const *histogramName,
Bool_t originalXAxisBinning,
646 Bool_t originalYAxisBinning,
char const *histogramTitle)
660 Int_t nBinX[3],axisListX[3];
662 xAxis->
GetTHxxBinning(originalXAxisBinning ? 1 : 0,nBinX,axisListX,0);
663 Int_t nBinY[3],axisListY[3];
665 yAxis->
GetTHxxBinning(originalYAxisBinning ? 1 : 0,nBinY,axisListY,0);
667 (histogramName,histogramTitle,axisListX[0],yAxis,axisListY[0]);
674 return new TH2D(histogramName,title,
678 return new TH2D(histogramName,title,
680 nBinY[0],0.5,0.5+nBinY[0]);
686 return new TH2D(histogramName,title,
687 nBinX[0],0.5,0.5+nBinX[0],
690 return new TH2D(histogramName,title,
691 nBinX[0],0.5,0.5+nBinX[0],
692 nBinY[0],0.5,0.5+nBinY[0]);
699 const char *axisSteering)
const 721 for(
Int_t i=0;i<3;i++) {
728 (maxDim,axisBins,axisList,axisSteering);
730 axisBins[0]=GetTHxxBinsRecursive(axisSteering);
787 Int_t isOptionGiven[3] = { 0 };
788 DecodeAxisSteering(axisSteering,
"CUO",isOptionGiven);
790 Int_t numDimension=GetDistributionDimension();
792 for(
Int_t i=0;i<numDimension;i++) {
793 if(isOptionGiven[0] & (1<<i))
continue;
796 if((r>0)&&(r<=maxDim)) {
802 for(
Int_t i=0;i<numDimension;i++) {
803 if(isOptionGiven[0] & (1<<i))
continue;
805 axisBins[
r]=GetDistributionBinning(i)->GetNrows()-1;
811 if(HasUnconnectedBins() || (GetDistributionNumberOfBins()<=0)) {
812 axisBins[0] = GetDistributionNumberOfBins();
815 for(
Int_t i=0;i<numDimension;i++) {
817 if(isOptionGiven[0] & mask)
continue;
818 Int_t nBinI=GetDistributionBinning(i)->GetNrows()-1;
819 if((fHasUnderflow & mask)&& !(isOptionGiven[1] & mask)) nBinI++;
820 if((fHasOverflow & mask)&& !(isOptionGiven[2] & mask)) nBinI++;
848 r +=child->GetTHxxBinsRecursive(axisSteering);
851 Int_t axisBins[3] = {0}, axisList[3] = {0};
852 GetTHxxBinningSingleNode(0,axisBins,axisList,axisSteering);
894 Int_t nMax=GetRootNode()->GetEndBin()+1;
896 for(
Int_t i=0;i<nMax;i++) {
899 Int_t startBin=GetRootNode()->GetStartBin();
903 FillBinMapSingleNode(hist,startBin,nDim,axisList,axisSteering,r);
905 Fatal(
"CreateBinMap",
"called with nDim=%d but GetNonemptyNode()=0",
909 FillBinMapRecursive(startBin,axisSteering,r);
915 (
Int_t startBin,
const char *axisSteering,
Int_t *binMap)
const 930 nbin = FillBinMapSingleNode(0,startBin,0,0,axisSteering,binMap);
933 nbin += child->FillBinMapRecursive(startBin+nbin,axisSteering,binMap);
940 const char *axisSteering,
Int_t *binMap)
const 973 Int_t isOptionGiven[3] = {0};
974 DecodeAxisSteering(axisSteering,
"CUO",isOptionGiven);
975 Int_t axisBins[MAXDIM] = {0};
976 Int_t dimension=GetDistributionDimension();
977 Int_t axisNbin[MAXDIM] = {0};
978 for(
Int_t i=0;i<dimension;i++) {
979 const TVectorD *binning=GetDistributionBinning(i);
982 for(
Int_t i=0;i<GetDistributionNumberOfBins();i++) {
983 Int_t globalBin=GetStartBin()+i;
987 Fatal(
"FillBinMapSingleNode",
988 "bin %d outside binning scheme",
991 Fatal(
"FillBinMapSingleNode",
992 "bin %d located in %s %d-%d rather than %s %d=%d",
993 i,(
const char *)dest->
GetName(),
995 (
const char *)
GetName(),GetStartBin(),GetEndBin());
1000 for(
Int_t axis=0;axis<dimension;axis++) {
1001 Int_t mask=(1<<axis);
1002 if(((axisBins[axis]<0)&&(isOptionGiven[1] & mask))||
1003 ((axisBins[axis]>=axisNbin[axis])&&(isOptionGiven[2] & mask)))
1012 ibin[0]=ibin[1]=ibin[2]=0;
1013 for(
Int_t hdim=0;hdim<nDim;hdim++) {
1014 Int_t axis=axisList[hdim];
1015 ibin[hdim]=axisBins[axis]+1;
1017 binMap[globalBin]=hist->
GetBin(ibin[0],ibin[1],ibin[2]);
1018 }
else if(nDim==1) {
1023 if(axisList[ii]>=0) {
1024 binMap[globalBin]=axisBins[axisList[ii]]+1;
1029 Fatal(
"FillBinMapSingleNode",
"unexpected bin mapping %d %d",nDim,
1039 for(
Int_t axis=dimension-1;axis>=0;axis--) {
1040 Int_t mask=(1<<axis);
1041 if(isOptionGiven[0] & mask) {
1045 Int_t iBin=axisBins[axis];
1046 Int_t nMax=axisNbin[axis];
1047 if((fHasUnderflow & ~isOptionGiven[1]) & mask) {
1051 if((fHasOverflow & ~isOptionGiven[2]) & mask) {
1056 binMap[globalBin] = startBin +
r;
1058 binMap[globalBin] = startBin + axisBins[0];
1065 for(
Int_t axis=dimension-1;axis>=0;axis--) {
1066 Int_t mask=(1<<axis);
1067 if(isOptionGiven[0] & mask) {
1071 Int_t nMax=axisNbin[axis];
1072 if((fHasUnderflow & ~isOptionGiven[1]) & mask) {
1075 if((fHasOverflow & ~isOptionGiven[2]) & mask) {
1081 nbin=GetDistributionNumberOfBins();
1087 (
const char *histogramName,
const TH1 *globalBins,
1088 const TH2 *globalBinsEmatrix,
Bool_t originalAxisBinning,
1089 const char *axisSteering)
const 1109 TH1 *
r=CreateHistogram(histogramName,originalAxisBinning,&binMap,0,
1114 if(binMap[iSrc]>nMax) nMax=binMap[iSrc];
1118 Int_t iDest=binMap[iSrc];
1122 if(!globalBinsEmatrix) {
1126 if(binMap[jSrc]==iDest) {
1134 for(
Int_t i=0;i<nMax;i++) {
1152 if(GetDistributionDimension()!=1) {
1153 Fatal(
"GetBinNumber",
1154 "called with 1 argument for %d dimensional distribution",
1155 GetDistributionDimension());
1157 return GetGlobalBinNumber(&x);
1165 if(GetDistributionDimension()!=2) {
1166 Fatal(
"GetBinNumber",
1167 "called with 2 arguments for %d dimensional distribution",
1168 GetDistributionDimension());
1173 return GetGlobalBinNumber(xx);
1182 if(GetDistributionDimension()!=3) {
1183 Fatal(
"GetBinNumber",
1184 "called with 3 arguments for %d dimensional distribution",
1185 GetDistributionDimension());
1191 return GetGlobalBinNumber(xx);
1200 if(GetDistributionDimension()!=4) {
1201 Fatal(
"GetBinNumber",
1202 "called with 4 arguments for %d dimensional distribution",
1203 GetDistributionDimension());
1210 return GetGlobalBinNumber(xx);
1218 if(!GetDistributionDimension()) {
1219 Fatal(
"GetBinNumber",
1220 "no axes are defined for node %s",
1223 Int_t iAxisBins[MAXDIM] = {0};
1224 for(
Int_t dim=0;dim<GetDistributionDimension();dim++) {
1229 if(x[dim]<(*bins)[i0]) {
1232 }
else if(x[dim]>=(*bins)[i1]) {
1238 if(x[dim]<(*bins)[i2]) {
1246 iAxisBins[dim]=iBin;
1248 Int_t r=ToGlobalBin(iAxisBins);
1259 Int_t axisBins[MAXDIM] = {0};
1268 for(
Int_t axis=0;axis<dimension;axis++) {
1269 TString thisAxisString=
1272 Int_t i=axisBins[axis];
1273 if(i<0) thisAxisString +=
"[ufl]";
1274 else if(i>=bins->
GetNrows()-1) thisAxisString +=
"[ofl]";
1279 axisString =
":"+thisAxisString+axisString;
1284 Int_t i=axisBins[0];
1285 if((i>=0)&&(i<distribution->fAxisLabelList->GetEntriesFast())) {
1302 Int_t axisBins[MAXDIM] = {0};
1309 Int_t pos=axisBins[axis];
1312 }
else if(pos>=bins->
GetNrows()-1) {
1315 r *= (*bins)(pos+1)-(*bins)(pos);
1327 Int_t axisBins[MAXDIM] = {0};
1334 for(
Int_t axis=0;axis<dimension;axis++) {
1336 (axis,axisBins[axis]);
1361 Int_t axisBins[MAXDIM] = {0};
1368 if((axis>=0)&&(axis<dimension)) {
1371 Int_t centerBin= axisBins[axis];
1372 axisBins[axis] =centerBin-1;
1373 *prev=ToGlobalBin(axisBins);
1378 axisBins[axis] =centerBin+1;
1379 *next=ToGlobalBin(axisBins);
1395 Int_t axisBins[MAXDIM] = {0};
1400 for(
Int_t axis=0;axis<dimension;axis++) {
1403 if(axisBins[axis]<0) *uStatus |= (1<<axis);
1404 if(axisBins[axis]>=nBin) *oStatus |= (1<<axis);
1410 (
Int_t binTHxx,
const char *axisSteering,
Int_t axisBins[MAXDIM])
const 1436 Int_t offset=binTHxx-GetStartBin();
1437 return GetBinLocationRecursive(offset,axisSteering,axisBins);
1441 (
Int_t &offset,
const char *axisSteering,
Int_t axisBins[MAXDIM])
const 1472 Int_t isOptionGiven[3] = { 0 };
1473 DecodeAxisSteering(axisSteering,
"CUO",isOptionGiven);
1476 if(GetDistributionDimension()>0) {
1479 for(
Int_t axis=0;axis<GetDistributionDimension();axis++) {
1481 if(isOptionGiven[0] & mask) {
1483 if((isOptionGiven[1] & mask)&&
1484 (fHasUnderflow & mask)) axisBins[axis] -= 1;
1485 if((isOptionGiven[2] & mask)&&
1486 (fHasOverflow & mask)) axisBins[axis] -= 2;
1488 Int_t nBin=GetDistributionBinning(axis)->GetNrows()-1;
1490 if((fHasUnderflow & mask) && !(isOptionGiven[1] & mask)) {
1494 if((fHasOverflow & mask) && !(isOptionGiven[2] & mask)) {
1497 axisBins[axis] += i % nBin;
1502 offset -= nBinsTotal;
1508 offset -= GetDistributionNumberOfBins();
1509 if(offset<0) r=
this;
1525 return (!GetDistributionDimension())&&(GetDistributionNumberOfBins()>0);
1536 if((axis>=0)&&(axis<GetDistributionDimension())) {
1537 TVectorD const *bins=GetDistributionBinning(axis);
1540 if(includeUnderflow && (fHasUnderflow & (1<<axis))) {
1541 Double_t w=GetDistributionUnderflowBinWidth(axis);
1547 if(includeOverflow && (fHasOverflow & (1<<axis))) {
1548 Double_t w=GetDistributionOverflowBinWidth(axis);
1558 Error(
"GetDistributionAverageBinSize",
"axis %d does not exist",axis);
1567 TVectorD const *bins=GetDistributionBinning(axis);
1568 return (*bins)[1]-(*bins)[0];
1575 TVectorD const *bins=GetDistributionBinning(axis);
1586 TVectorD const *bins=GetDistributionBinning(axis);
1590 r=(*bins)[0]-0.5*GetDistributionUnderflowBinWidth(axis);
1591 }
else if(bin>=bins->
GetNrows()-1) {
1593 r=(*bins)[bins->
GetNrows()-1]+0.5*GetDistributionOverflowBinWidth(axis);
1595 r=0.5*((*bins)[bin+1]+(*bins)[bin]);
1605 Int_t dimension=GetDistributionDimension();
1608 for(
Int_t axis=dimension-1;axis>=0;axis--) {
1609 Int_t nMax=GetDistributionBinning(axis)->GetNrows()-1;
1610 Int_t i=axisBins[axis];
1611 if(fHasUnderflow & (1<<axis)) {
1615 if(fHasOverflow & (1<<axis)) nMax +=1;
1616 if((i>=0)&&(i<nMax)) {
1627 if((axisBins[0]>=0)&&(axisBins[0]<GetDistributionNumberOfBins()))
1628 r=GetStartBin()+axisBins[0];
1650 if((globalBin>=GetStartBin())&&(globalBin<GetEndBin())) {
1652 for(node=GetChildNode();node && !
r; node=node->
GetNextNode()) {
1657 Int_t i=globalBin-GetStartBin();
1658 Int_t dimension=GetDistributionDimension();
1660 for(
int axis=0;axis<dimension;axis++) {
1661 Int_t nMax=GetDistributionBinning(axis)->GetNrows()-1;
1663 if(fHasUnderflow & (1<<axis)) {
1667 if(fHasOverflow & (1<<axis)) nMax +=1;
1668 axisBins[axis] += i % nMax;
1680 (
const char *axisSteering,
const char *options,
Int_t *isOptionGiven)
const 1710 Int_t nOpt=TString(options).Length();
1711 for(
Int_t i=0;i<nOpt;i++) isOptionGiven[i]=0;
1713 TObjArray *patterns=TString(axisSteering).Tokenize(
";");
1715 Int_t nAxis=fAxisLabelList->GetEntries();
1716 for(
Int_t i=0;i<nPattern;i++) {
1719 Int_t bracketBegin=pattern.Last(
'[');
1720 Int_t len=pattern.Length();
1721 if((bracketBegin>0)&&(pattern[len-1]==
']')) {
1722 TString axisId=
pattern(0,bracketBegin);
1724 if((axisId[0]==
'*')&&(axisId.Length()==1)) {
1729 for(
Int_t j=0;j<nAxis;j++) {
1730 if(!axisId.CompareTo(GetDistributionAxisLabel(j))) {
1735 for(
Int_t o=0;o<nOpt;o++) {
1736 if(pattern.Last(options[o])>bracketBegin) {
1737 isOptionGiven[o] |= mask;
1741 Error(
"DecodeAxisSteering",
1742 "steering \"%s\" does not end with [options]",
1743 (
const char *)pattern);
const TUnfoldBinning * GetBinLocation(Int_t binTHxx, const char *axisSteering, Int_t axisBins[MAXDIM]) const
virtual const char * GetName() const
Returns name of object.
std::string GetName(const std::string &scope_name)
TUnfoldBinning * parentNode
TH1 * CreateHistogram(const char *histogramName, Bool_t originalAxisBinning=kFALSE, Int_t **binMap=0, const char *histogramTitle=0, const char *axisSteering=0) const
TH2D * CreateErrorMatrixHistogram(const char *histogramName, Bool_t originalAxisBinning, Int_t **binMap=0, const char *histogramTitle=0, const char *axisSteering=0) const
virtual Double_t GetDistributionBinCenter(Int_t axis, Int_t bin) const
const TUnfoldBinning * GetNonemptyNode(void) const
void Fatal(const char *location, const char *msgfmt,...)
Collectable string class.
virtual Double_t GetBinLowEdge(Int_t bin) const
Return low edge of bin.
virtual Double_t GetDistributionAverageBinSize(Int_t axis, Bool_t includeUnderflow, Bool_t includeOverflow) const
Int_t * CreateBinMap(const TH1 *hist, Int_t nDim, const Int_t *axisList, const char *axisSteering) const
TString BuildHistogramTitle2D(const char *histogramName, const char *histogramTitle, Int_t xAxis, const TUnfoldBinning *yAxisBinning, Int_t yAxis) const
TUnfoldBinning const * ToAxisBins(Int_t globalBin, Int_t *axisBins) const
Double_t GetBinSize(Int_t iBin) const
virtual Double_t GetBinContent(Int_t bin) const
Return content of bin number bin.
TUnfoldBinning * nextNode
void GetBinNeighbours(Int_t globalBin, Int_t axis, Int_t *prev, Double_t *distPrev, Int_t *next, Double_t *distNext) const
void GetBinUnderflowOverflowStatus(Int_t iBin, Int_t *uStatus, Int_t *oStatus) const
void PrintStream(std::ostream &out, Int_t indent=0) const
TObject * At(Int_t idx) const
Int_t GetTHxxBinning(Int_t maxDim, Int_t *axisBins, Int_t *axisList, const char *axisSteering) const
virtual ~TUnfoldBinning(void)
LongDouble_t Power(LongDouble_t x, LongDouble_t y)
TUnfoldBinning const * GetNextNode(void) const
virtual Double_t GetBinUpEdge(Int_t bin) const
Return up edge of bin.
Int_t UpdateFirstLastBin(Bool_t startWithRootNode=kTRUE)
Double_t fBinFactorConstant
virtual Int_t GetDimension() const
const TUnfoldBinning * GetBinLocationRecursive(Int_t &offset, const char *axisSteering, Int_t axisBins[MAXDIM]) const
static const double x2[5]
Int_t GetEndBin(void) const
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString...
Int_t ToGlobalBin(Int_t const *axisBins) const
The TNamed class is the base class for all named ROOT classes.
void Info(const char *location, const char *msgfmt,...)
Int_t GetStartBin(void) const
virtual void SetBinError(Int_t bin, Double_t error)
See convention for numbering bins in TH1::GetBin.
void Error(const char *location, const char *msgfmt,...)
TVectorT< Double_t > TVectorD
TVectorD const * GetDistributionBinning(Int_t axis) const
Int_t GetDistributionDimension(void) const
Element * GetMatrixArray()
TUnfoldBinning const * GetParentNode(void) const
THist< 3, double, THistStatContent, THistStatUncertainty > TH3D
TH1 * ExtractHistogram(const char *histogramName, const TH1 *globalBins, const TH2 *globalBinsEmatrix=0, Bool_t originalAxisBinning=kTRUE, const char *axisSteering=0) const
Bool_t AddAxis(const char *name, Int_t nBins, const Double_t *binBorders, Bool_t hasUnderflow, Bool_t hasOverflow)
void DecodeAxisSteering(const char *axisSteering, const char *options, Int_t *isOptionGiven) const
const char * GetTitle() const
Returns title of object.
Service class for 2-Dim histogram classes.
Class to manage histogram axis.
void Initialize(Bool_t useTMVAStyle=kTRUE)
virtual Double_t GetDistributionUnderflowBinWidth(Int_t axis) const
virtual void SetBinContent(Int_t bin, Double_t content)
Set bin content see convention for numbering bins in TH1::GetBin In case the bin number is greater th...
TUnfoldBinning const * GetPrevNode(void) const
static void indent(ostringstream &buf, int indent_level)
void Warning(const char *location, const char *msgfmt,...)
virtual Int_t GetBin(Int_t binx, Int_t biny=0, Int_t binz=0) const
Return Global bin number corresponding to binx,y,z.
static TH2D * CreateHistogramOfMigrations(TUnfoldBinning const *xAxis, TUnfoldBinning const *yAxis, char const *histogramName, Bool_t originalXAxisBinning=kFALSE, Bool_t originalYAxisBinning=kFALSE, char const *histogramTitle=0)
This class serves as a container of analysis bins analysis bins are specified by defining the axes of...
virtual Double_t Eval(Double_t x, Double_t y=0, Double_t z=0, Double_t t=0) const
Evaluate this function.
TString GetDistributionAxisLabel(Int_t axis) const
static const double x1[5]
TUnfoldBinning * prevNode
THist< 2, double, THistStatContent, THistStatUncertainty > TH2D
Int_t FillBinMapSingleNode(const TH1 *hist, Int_t startBin, Int_t nDim, const Int_t *axisList, const char *axisSteering, Int_t *binMap) const
Int_t GetGlobalBinNumber(Double_t x) const
TString GetBinName(Int_t iBin) const
you should not use this method at all Int_t Int_t z
Int_t GetTH1xNumberOfBins(Bool_t originalAxisBinning=kTRUE, const char *axisSteering=0) const
Int_t FillBinMapRecursive(Int_t startBin, const char *axisSteering, Int_t *binMap) const
typedef void((*Func_t)())
Bool_t HasUnconnectedBins(void) const
virtual Double_t GetDistributionOverflowBinWidth(Int_t axis) const
#define dest(otri, vertexptr)
TUnfoldBinning(const char *name=0, Int_t nBins=0, const char *binNames=0)
THist< 1, double, THistStatContent, THistStatUncertainty > TH1D
Int_t GetEntries() const
Return the number of objects in array (i.e.
Int_t GetTHxxBinningSingleNode(Int_t maxDim, Int_t *axisBins, Int_t *axisList, const char *axisSteering) const
virtual Double_t * GetParameters() const
Double_t Sqrt(Double_t x)
TString BuildHistogramTitle(const char *histogramName, const char *histogramTitle, Int_t const *axisList) const
virtual Double_t EvalPar(const Double_t *x, const Double_t *params=0)
Evaluate function with given coordinates and parameters.
Int_t GetTHxxBinsRecursive(const char *axisSteering) const
TUnfoldBinning * GetRootNode(void)
TUnfoldBinning * AddBinning(TUnfoldBinning *binning)
static char * skip(char **buf, const char *delimiters)
TUnfoldBinning const * FindNode(char const *name) const
virtual Double_t GetBinFactor(Int_t iBin) const
virtual Double_t GetBinError(Int_t bin) const
Return value of error associated to bin number bin.
static const double x3[11]
tomato 2-D histogram with a double per channel (see TH1 documentation)}