BAT  0.9.4
The Bayesian analysis toolkit
 All Classes Namespaces Functions Variables Enumerations
BCGoFTest.h
1 #ifndef __BCGOFTEST__H
2 #define __BCGOFTEST__H
3 
14 /*
15  * Copyright (C) 2007-2014, the BAT core developer team
16  * All rights reserved.
17  *
18  * For the licensing terms see doc/COPYING.
19  * For documentation see http://mpp.mpg.de/bat
20  */
21 
22 // ---------------------------------------------------------
23 
24 #include "BCModel.h"
25 
26 // ROOT classes
27 class TH1D;
28 
29 // BAT classes
30 class BCDataSet;
31 
32 // ---------------------------------------------------------
33 
34 class BCGoFTest : public BCModel
35 {
36  public:
37 
44  BCGoFTest(const char * name);
45 
48  ~BCGoFTest();
49 
58  double GetCalculatedPValue(bool flag_histogram = false);
59 
63  { return fHistogramLogProb; };
64 
68  { return fTestModel; };
69 
77  void SetTestModel(BCModel * testmodel)
78  { fTestModel = testmodel; };
79 
84  int SetTestPoint(std::vector<double> parameters);
85 
90  double LogLikelihood(const std::vector<double> &parameters);
91 
92  double LogAPrioriProbability(const std::vector<double> & /*parameters*/)
93  { return 0; };
94 
95  void MCMCUserIterationInterface();
96 
99  private:
100 
103  std::vector<int> fMapDataPoint;
104  std::vector<int> fMapDataValue;
105 
108  int fPValueBelow;
109  int fPValueAbove;
110 
113  BCModel * fTestModel;
114 
117  BCDataSet * fTemporaryDataSet;
118 
121  double fLogLikelihood;
122  double fLogLikelihoodMin;
123  double fLogLikelihoodMax;
124 
127  TH1D * fHistogramLogProb;
128 };
129 
130 // ---------------------------------------------------------
131 
132 #endif
int SetTestPoint(std::vector< double > parameters)
Definition: BCGoFTest.cxx:123
TH1D * GetHistogramLogProb()
Definition: BCGoFTest.h:62
void SetTestModel(BCModel *testmodel)
Definition: BCGoFTest.h:77
double LogAPrioriProbability(const std::vector< double > &)
Definition: BCGoFTest.h:92
The base class for all user-defined models.
Definition: BCModel.h:50
A class representing a set of data points.
Definition: BCDataSet.h:37
BCGoFTest(const char *name)
Definition: BCGoFTest.cxx:23
The class for testing model hypotheses.
Definition: BCGoFTest.h:34
double GetCalculatedPValue(bool flag_histogram=false)
Definition: BCGoFTest.cxx:227
BCModel * GetTestModel()
Definition: BCGoFTest.h:67
double LogLikelihood(const std::vector< double > &parameters)
Definition: BCGoFTest.cxx:77