class RooStats::ProfileLikelihoodCalculator: public RooStats::CombinedCalculator

```
```

ProfileLikelihoodCalculator is a concrete implementation of CombinedCalculator (the interface class for a tools which can produce both RooStats HypoTestResults and ConfIntervals). The tool uses the profile likelihood ratio as a test statistic, and assumes that Wilks' theorem is valid. Wilks' theorem states that -2* log (profile likelihood ratio) is asymptotically distributed as a chi^2 distribution with N-dof, where N is the number of degrees of freedom. Thus, p-values can be constructed and the profile likelihood ratio can be used to construct a LikelihoodInterval. (In the future, this class could be extended to use toy Monte Carlo to calibrate the distribution of the test statistic).

Usage: It uses the interface of the CombinedCalculator, so that it can be configured by specifying:

• a model common model (eg. a family of specific models which includes both the null and alternate),
• a data set,
• a set of parameters of interest. The nuisance parameters will be all other parameters of the model
• a set of parameters of which specify the null hypothesis (including values and const/non-const status)
The interface allows one to pass the model, data, and parameters either directly or via a ModelConfig class. The alternate hypothesis leaves the parameter free to take any value other than those specified by the null hypotesis. There is therefore no need to specify the alternate parameters.

After configuring the calculator, one only needs to ask GetHypoTest() (which will return a HypoTestResult pointer) or GetInterval() (which will return an ConfInterval pointer).

The concrete implementations of this interface should deal with the details of how the nuisance parameters are dealt with (eg. integration vs. profiling) and which test-statistic is used (perhaps this should be added to the interface).

The motivation for this interface is that we hope to be able to specify the problem in a common way for several concrete calculators.

```

```

Function Members (Methods)

public:
 virtual ~ProfileLikelihoodCalculator() static TClass* Class() RooStats::CombinedCalculator RooStats::CombinedCalculator::CombinedCalculator() RooStats::CombinedCalculator RooStats::CombinedCalculator::CombinedCalculator(const RooStats::CombinedCalculator&) RooStats::CombinedCalculator RooStats::CombinedCalculator::CombinedCalculator(RooAbsData& data, const RooStats::ModelConfig& model, Double_t size = 0.050000000000000003) RooStats::CombinedCalculator RooStats::CombinedCalculator::CombinedCalculator(RooAbsData& data, RooAbsPdf& pdf, const RooArgSet& paramsOfInterest, Double_t size = 0.050000000000000003, const RooArgSet* nullParams = 0, const RooArgSet* altParams = 0, const RooArgSet* nuisParams = 0) virtual Double_t RooStats::CombinedCalculator::ConfidenceLevel() const virtual RooStats::HypoTestResult* GetHypoTest() const virtual RooStats::LikelihoodInterval* GetInterval() const RooStats::HypoTestCalculator RooStats::HypoTestCalculator::HypoTestCalculator() RooStats::HypoTestCalculator RooStats::HypoTestCalculator::HypoTestCalculator(const RooStats::HypoTestCalculator&) RooStats::IntervalCalculator RooStats::IntervalCalculator::IntervalCalculator() RooStats::IntervalCalculator RooStats::IntervalCalculator::IntervalCalculator(const RooStats::IntervalCalculator&) virtual TClass* IsA() const RooStats::ProfileLikelihoodCalculator& operator=(const RooStats::ProfileLikelihoodCalculator&) RooStats::ProfileLikelihoodCalculator ProfileLikelihoodCalculator() RooStats::ProfileLikelihoodCalculator ProfileLikelihoodCalculator(const RooStats::ProfileLikelihoodCalculator&) RooStats::ProfileLikelihoodCalculator ProfileLikelihoodCalculator(RooAbsData& data, RooStats::ModelConfig& model, Double_t size = 0.050000000000000003) RooStats::ProfileLikelihoodCalculator ProfileLikelihoodCalculator(RooAbsData& data, RooAbsPdf& pdf, const RooArgSet& paramsOfInterest, Double_t size = 0.050000000000000003, const RooArgSet* nullParams = 0) virtual void RooStats::CombinedCalculator::SetAlternateModel(const RooStats::ModelConfig&) virtual void RooStats::CombinedCalculator::SetAlternateParameters(const RooArgSet& set) virtual void RooStats::HypoTestCalculator::SetCommonModel(const RooStats::ModelConfig& model) virtual void RooStats::CombinedCalculator::SetConditionalObservables(const RooArgSet& set) virtual void RooStats::CombinedCalculator::SetConfidenceLevel(Double_t cl) virtual void RooStats::CombinedCalculator::SetData(RooAbsData& data) virtual void RooStats::CombinedCalculator::SetModel(const RooStats::ModelConfig& model) virtual void RooStats::CombinedCalculator::SetNuisanceParameters(const RooArgSet& set) virtual void RooStats::CombinedCalculator::SetNullModel(const RooStats::ModelConfig&) virtual void RooStats::CombinedCalculator::SetNullParameters(const RooArgSet& set) virtual void RooStats::CombinedCalculator::SetParameters(const RooArgSet& set) virtual void RooStats::CombinedCalculator::SetPdf(RooAbsPdf& pdf) virtual void RooStats::CombinedCalculator::SetTestSize(Double_t size) virtual void ShowMembers(TMemberInspector& insp) const virtual Double_t RooStats::CombinedCalculator::Size() const virtual void Streamer(TBuffer&) void StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
protected:
 RooAbsReal* DoGlobalFit() const static RooFitResult* DoMinimizeNLL(RooAbsReal* nll) void DoReset() const RooAbsData* RooStats::CombinedCalculator::GetData() const RooAbsPdf* RooStats::CombinedCalculator::GetPdf() const

Data Members

protected:
 RooArgSet RooStats::CombinedCalculator::fAlternateParams RooArgSet specifying alternate parameters for hypothesis test // Is it used ???? RooArgSet RooStats::CombinedCalculator::fConditionalObs RooArgSet specifying the conditional observables RooAbsData* RooStats::CombinedCalculator::fData RooFitResult* fFitResult internal result of gloabl fit bool fGlobalFitDone flag to control if a global fit has been done RooArgSet RooStats::CombinedCalculator::fNuisParams RooArgSet specifying nuisance parameters for interval RooArgSet RooStats::CombinedCalculator::fNullParams RooArgSet specifying null parameters for hypothesis test RooArgSet RooStats::CombinedCalculator::fPOI RooArgSet specifying parameters of interest for interval RooAbsPdf* RooStats::CombinedCalculator::fPdf Double_t RooStats::CombinedCalculator::fSize size of the test (eg. specified rate of Type I error)

Function documentation

``` default constructor
```
ProfileLikelihoodCalculator(RooAbsData& data, RooAbsPdf& pdf, const RooArgSet& paramsOfInterest, Double_t size = 0.050000000000000003, const RooArgSet* nullParams = 0)
``` constructor from pdf and parameters
the pdf must contain eventually the nuisance parameters
```
ProfileLikelihoodCalculator(RooAbsData& data, RooStats::ModelConfig& model, Double_t size = 0.050000000000000003)
``` construct from a ModelConfig. Assume data model.GetPdf() will provide full description of model including
constraint term on the nuisances parameters
```

``` destructor
cannot delete prod pdf because it will delete all the composing pdf's
if (fOwnPdf) delete fPdf;
fPdf = 0;
```
void DoReset() const
``` reset and clear fit result
to be called when a new model or data are set in the calculator
```
RooAbsReal * DoGlobalFit() const
``` perform a global fit of the likelihood letting with all parameter of interest and
nuisance parameters
keep the list of fitted parameters
```

``` Minimizer the given NLL using the default options
```
LikelihoodInterval* GetInterval() const
``` Main interface to get a RooStats::ConfInterval.
It constructs a profile likelihood ratio and uses that to construct a RooStats::LikelihoodInterval.
```
HypoTestResult* GetHypoTest() const
``` Main interface to get a HypoTestResult.
It does two fits:
the first lets the null parameters float, so it's a maximum likelihood estimate
the second is to the null (fixing null parameters to their specified values): eg. a conditional maximum likelihood
the ratio of the likelihood at the conditional MLE to the MLE is the profile likelihood ratio.
Wilks' theorem is used to get p-values
```

``` default constructor (needed for I/O)
```