ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/JetFitAnalyzer/interface/HistoFitter.h
(Generate patch)

Comparing UserCode/JetFitAnalyzer/interface/HistoFitter.h (file contents):
Revision 1.6 by dnisson, Sun Jan 10 01:36:29 2010 UTC vs.
Revision 1.8 by dnisson, Sat Feb 6 00:03:24 2010 UTC

# Line 1 | Line 1
1   // Original Author: David Nisson
2 < // A histogram fitter
2 > // Fits a two-dimensional model in eta and phi consisting of summed
3 > // Gaussians to a histogram, supplied in the function fit_histo.
4 > // This histogram can be of mass, energy, or momentum.
5  
6   #ifndef UserCode_JetFitAnalyzer_HistoFitter_h
7   #define UserCode_JetFitAnalyzer_HistoFitter_h
# Line 20 | Line 22 | public:
22                                     double YbinSize,
23                                     double cutoffRad = 0.2);
24  
25 +  // place where fitting trouble happened
26    enum TroubleStage {
27      T_NULL = 0,
28      T_SIMPLEX,
# Line 27 | Line 30 | public:
30      T_MINOS
31    };
32  
33 +  // the histogram class used internally by HistoFitter
34    struct VectorHisto {
35      std::vector< std::vector<double> > bins;
36      double Xlo, Xhi, Ylo, Yhi;
37    };
38  
39 +  // information about fitting trouble
40    struct Trouble {
41      TroubleStage occ;
42      int istat;
43    };
44  
45 +  // structure that stores the fit results
46    struct FitResults {
47      TH2 *rebinnedHisto;
48      std::vector< double > chisquare;
# Line 106 | Line 112 | public:
112    int getNumberOfDegreesOfFreedom(VectorHisto, int);
113  
114    FitResults putParsInFitResults(std::vector<TString>,
115 <                                 double *, double *, double *, double *);
115 >                                 double *, double *, double *, double *,
116 >                                 FitResults&);
117    static VectorHisto loadTH2IntoVectorHisto(TH2*);
118    Trouble minimize(TMinuit*, VectorHisto, int);
119  
# Line 121 | Line 128 | public:
128  
129    double fitFunction_TF2(double *, double *);
130   protected:
124  ModelDefinition *mdef;
131    static ModelDefinition *static_mdef;
132    static VectorHisto energy;
133   };

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines