laura is hosted by Hepforge, IPPP Durham
Laura++  v3r5
A maximum likelihood fitting package for performing Dalitz-plot analysis.
LauFitNtuple.hh
Go to the documentation of this file.
1 
2 /*
3 Copyright 2004 University of Warwick
4 
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8 
9  http://www.apache.org/licenses/LICENSE-2.0
10 
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16 */
17 
18 /*
19 Laura++ package authors:
20 John Back
21 Paul Harrison
22 Thomas Latham
23 */
24 
37 //****************************************************************************
38 // Class to store the results from the fit/toy MC into an ntuple
39 // -- CLASS DESCRIPTION [MISC] --
41 
42 #ifndef LAU_FIT_NTUPLE
43 #define LAU_FIT_NTUPLE
44 
45 #include <vector>
46 
47 #include "TMatrixDfwd.h"
48 #include "TString.h"
49 
50 #include "LauAbsFitter.hh"
51 
52 class TFile;
53 class TTree;
54 
55 class LauParameter;
56 
57 
58 class LauFitNtuple {
59 
60  public:
62 
66  LauFitNtuple(const TString& fileName, Bool_t storeAsymErrors);
67 
69  virtual ~LauFitNtuple();
70 
72 
77  void storeCorrMatrix(const UInt_t iExpt, const LauAbsFitter::FitStatus& fitStatus, const TMatrixD& covMatrix);
78 
80 
84  void storeParsAndErrors(const std::vector<LauParameter*>& fitVars, const std::vector<LauParameter>& extraVars);
85 
87  void updateFitNtuple();
88 
90  void writeOutFitResults();
91 
92  private:
94  LauFitNtuple(const LauFitNtuple& rhs);
95 
97  LauFitNtuple& operator=(const LauFitNtuple& rhs);
98 
100  TString rootFileName_;
102  TFile* rootFile_;
104  TTree* fitResults_;
105 
107  std::vector<LauParameter*> fitVars_;
109  std::vector<LauParameter> extraVars_;
110 
112  std::vector< std::vector<Double_t> > corrMatrix_;
113 
118 
122  UInt_t nFitPars_;
124  UInt_t nFreePars_;
126  UInt_t nExtraPars_;
128  Int_t iExpt_;
129 
130  ClassDef(LauFitNtuple,0) // Fit/toyMC results ntuple
131 
132 };
133 
134 #endif
Bool_t definedFitTree_
Flags whether the fit tree has been defined.
std::vector< LauParameter * > fitVars_
Fit variables.
Int_t iExpt_
Experiment number.
UInt_t nExtraPars_
Number of extra parameters.
File containing declaration of LauAbsFitter class.
LauAbsFitter::FitStatus fitStatus_
Status of fit.
std::vector< std::vector< Double_t > > corrMatrix_
Correlation matrix.
std::vector< LauParameter > extraVars_
Extra variables.
void updateFitNtuple()
Update the fit ntuple.
TFile * rootFile_
Root file.
UInt_t nFitPars_
Number of fit parameters.
void storeCorrMatrix(const UInt_t iExpt, const LauAbsFitter::FitStatus &fitStatus, const TMatrixD &covMatrix)
Store the correlation matrix and other fit information.
Definition: LauFitNtuple.cc:74
void writeOutFitResults()
Write out fit results.
LauFitNtuple(const TString &fileName, Bool_t storeAsymErrors)
Constructor.
Definition: LauFitNtuple.cc:46
Struct to store fit status information.
Definition: LauAbsFitter.hh:55
Class for defining the fit parameter objects.
Definition: LauParameter.hh:49
virtual ~LauFitNtuple()
Destructor.
Definition: LauFitNtuple.cc:66
void storeParsAndErrors(const std::vector< LauParameter * > &fitVars, const std::vector< LauParameter > &extraVars)
Store parameters and their errors.
TTree * fitResults_
Fit results.
Class to store the results from the fit into an ntuple.
Definition: LauFitNtuple.hh:58
TString rootFileName_
Name of root file.
LauFitNtuple & operator=(const LauFitNtuple &rhs)
Copy assignment operator (not implemented)
UInt_t nFreePars_
Number of free parameters.
Bool_t storeAsymErrors_
Flags whether or not to store the asymmetric error information.