Logo ROOT  
Reference Guide
RooFitResult Class Reference

RooFitResult is a container class to hold the input and output of a PDF fit to a dataset.

It contains:

  • Values of all constant parameters
  • Initial and final values of floating parameters with error
  • Correlation matrix and global correlation coefficients
  • NLL and EDM at mininum

No references to the fitted PDF and dataset are stored

Definition at line 40 of file RooFitResult.h.

Public Member Functions

 RooFitResult (const char *name=0, const char *title=0)
 Constructor with name and title. More...
 
 RooFitResult (const RooFitResult &other)
 Copy constructor. More...
 
 ~RooFitResult () override
 Destructor. More...
 
virtual TObjectclone () const
 
TObjectClone (const char *newname=0) const override
 Make a clone of an object using the Streamer facility. More...
 
TMatrixDSym conditionalCovarianceMatrix (const RooArgList &params) const
 Return a reduced covariance matrix, which is calculated as. More...
 
const RooArgListconstPars () const
 Return list of constant parameters. More...
 
const RooArgListcorrelation (const char *parname) const
 Return the set of correlation coefficients of parameter 'par' with all other floating parameters. More...
 
double correlation (const char *parname1, const char *parname2) const
 Return the correlation between parameters 'par1' and 'par2'. More...
 
const RooArgListcorrelation (const RooAbsArg &par) const
 Return pointer to list of correlations of all parameters with par. More...
 
double correlation (const RooAbsArg &par1, const RooAbsArg &par2) const
 Return correlation between par1 and par2. More...
 
TH2correlationHist (const char *name="correlation_matrix") const
 Return TH2D of correlation matrix. More...
 
const TMatrixDSymcorrelationMatrix () const
 Return correlation matrix ;. More...
 
const TMatrixDSymcovarianceMatrix () const
 Return covariance matrix. More...
 
Int_t covQual () const
 Return MINUIT quality code of covariance matrix. More...
 
RooAbsPdfcreateHessePdf (const RooArgSet &params) const
 Return a p.d.f that represents the fit result as a multi-variate probability densisty function on the floating fit parameters, including correlations. More...
 
Int_t defaultPrintContents (Option_t *opt) const override
 Configure default contents to be printed. More...
 
StyleOption defaultPrintStyle (Option_t *opt) const override
 Configure mapping of Print() arguments to RooPrintable print styles. More...
 
double edm () const
 Return estimated distance to minimum. More...
 
const RooArgListfloatParsFinal () const
 Return list of floating parameters after fit. More...
 
const RooArgListfloatParsInit () const
 Return list of floating parameters before fit. More...
 
const RooArgListglobalCorr ()
 Return the list of all global correlations. More...
 
double globalCorr (const char *parname)
 Return the global correlation of the named parameter. More...
 
double globalCorr (const RooAbsArg &par)
 
TClassIsA () const override
 
bool isIdentical (const RooFitResult &other, double tol=1e-6, double tolCorr=1e-4, bool verbose=true) const
 Return true if this fit result is identical to other within tolerances. More...
 
bool isIdenticalNoCov (const RooFitResult &other, double tol=1e-6, double tolErr=1e-3, bool verbose=true) const
 Return true if this fit result is identical to other within tolerances, ignoring the correlation matrix. More...
 
double minNll () const
 Return minimized -log(L) value. More...
 
Int_t numInvalidNLL () const
 Return number of NLL evaluations with problems. More...
 
UInt_t numStatusHistory () const
 
RooPlotplotOn (RooPlot *frame, const RooAbsArg &par1, const RooAbsArg &par2, const char *options="ME") const
 Add objects to a 2D plot. More...
 
RooPlotplotOn (RooPlot *plot, const char *parName1, const char *parName2, const char *options="ME") const
 Add objects to a 2D plot that represent the fit results for the two named parameters. More...
 
void Print (Option_t *options=0) const override
 Print TNamed name and title. More...
 
void printArgs (std::ostream &os) const override
 Print arguments of fit result, i.e. the parameters of the fit. More...
 
void printClassName (std::ostream &os) const override
 Print class name of fit result. More...
 
void printMultiline (std::ostream &os, Int_t contents, bool verbose=false, TString indent="") const override
 Print fit result to stream 'os'. More...
 
void printName (std::ostream &os) const override
 Print name of fit result. More...
 
void printTitle (std::ostream &os) const override
 Print title of fit result. More...
 
void printValue (std::ostream &os) const override
 Print the value of the fit result, i.e.g the status, minimized FCN, edm and covariance quality code. More...
 
const RooArgListrandomizePars () const
 Generate random perturbations of the final parameters using the covariance matrix. More...
 
TMatrixDSym reducedCovarianceMatrix (const RooArgList &params) const
 Return a reduced covariance matrix (Note that Vred is a simple sub-matrix of V, row/columns are ordered to matched the convention given in input argument 'params'. More...
 
void SetName (const char *name) override
 Change name of RooFitResult object. More...
 
void SetNameTitle (const char *name, const char *title) override
 Change name and title of RooFitResult object. More...
 
Int_t status () const
 Return MINUIT status code. More...
 
Int_t statusCodeHistory (UInt_t icycle) const
 
const char * statusLabelHistory (UInt_t icycle) const
 
void Streamer (TBuffer &) override
 Stream an object of class RooFitResult. More...
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
- Public Member Functions inherited from TNamed
 TNamed ()
 
 TNamed (const char *name, const char *title)
 
 TNamed (const TNamed &named)
 TNamed copy ctor. More...
 
 TNamed (const TString &name, const TString &title)
 
virtual ~TNamed ()
 TNamed destructor. More...
 
void Clear (Option_t *option="") override
 Set name and title to empty strings (""). More...
 
TObjectClone (const char *newname="") const override
 Make a clone of an object using the Streamer facility. More...
 
Int_t Compare (const TObject *obj) const override
 Compare two TNamed objects. More...
 
void Copy (TObject &named) const override
 Copy this to obj. More...
 
virtual void FillBuffer (char *&buffer)
 Encode TNamed into output buffer. More...
 
const char * GetName () const override
 Returns name of object. More...
 
const char * GetTitle () const override
 Returns title of object. More...
 
ULong_t Hash () const override
 Return hash value for this object. More...
 
TClassIsA () const override
 
Bool_t IsSortable () const override
 
void ls (Option_t *option="") const override
 List TNamed name and title. More...
 
TNamedoperator= (const TNamed &rhs)
 TNamed assignment operator. More...
 
void Print (Option_t *option="") const override
 Print TNamed name and title. More...
 
virtual void SetName (const char *name)
 Set the name of the TNamed. More...
 
virtual void SetNameTitle (const char *name, const char *title)
 Set all the TNamed parameters (name and title). More...
 
virtual void SetTitle (const char *title="")
 Set the title of the TNamed. More...
 
virtual Int_t Sizeof () const
 Return size of the TNamed part of the TObject. More...
 
void Streamer (TBuffer &) override
 Stream an object of class TObject. More...
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
- Public Member Functions inherited from TObject
 TObject ()
 TObject constructor. More...
 
 TObject (const TObject &object)
 TObject copy ctor. More...
 
virtual ~TObject ()
 TObject destructor. More...
 
void AbstractMethod (const char *method) const
 Use this method to implement an "abstract" method that you don't want to leave purely abstract. More...
 
virtual void AppendPad (Option_t *option="")
 Append graphics object to current pad. More...
 
virtual void Browse (TBrowser *b)
 Browse object. May be overridden for another default action. More...
 
ULong_t CheckedHash ()
 Check and record whether this class has a consistent Hash/RecursiveRemove setup (*) and then return the regular Hash value for this object. More...
 
virtual const char * ClassName () const
 Returns name of class to which the object belongs. More...
 
virtual void Clear (Option_t *="")
 
virtual TObjectClone (const char *newname="") const
 Make a clone of an object using the Streamer facility. More...
 
virtual Int_t Compare (const TObject *obj) const
 Compare abstract method. More...
 
virtual void Copy (TObject &object) const
 Copy this to obj. More...
 
virtual void Delete (Option_t *option="")
 Delete this object. More...
 
virtual Int_t DistancetoPrimitive (Int_t px, Int_t py)
 Computes distance from point (px,py) to the object. More...
 
virtual void Draw (Option_t *option="")
 Default Draw method for all objects. More...
 
virtual void DrawClass () const
 Draw class inheritance tree of the class to which this object belongs. More...
 
virtual TObjectDrawClone (Option_t *option="") const
 Draw a clone of this object in the current selected pad for instance with: gROOT->SetSelectedPad(gPad). More...
 
virtual void Dump () const
 Dump contents of object on stdout. More...
 
virtual void Error (const char *method, const char *msgfmt,...) const
 Issue error message. More...
 
virtual void Execute (const char *method, const char *params, Int_t *error=0)
 Execute method on this object with the given parameter string, e.g. More...
 
virtual void Execute (TMethod *method, TObjArray *params, Int_t *error=0)
 Execute method on this object with parameters stored in the TObjArray. More...
 
virtual void ExecuteEvent (Int_t event, Int_t px, Int_t py)
 Execute action corresponding to an event at (px,py). More...
 
virtual void Fatal (const char *method, const char *msgfmt,...) const
 Issue fatal error message. More...
 
virtual TObjectFindObject (const char *name) const
 Must be redefined in derived classes. More...
 
virtual TObjectFindObject (const TObject *obj) const
 Must be redefined in derived classes. More...
 
virtual Option_tGetDrawOption () const
 Get option used by the graphics system to draw this object. More...
 
virtual const char * GetIconName () const
 Returns mime type name of object. More...
 
virtual const char * GetName () const
 Returns name of object. More...
 
virtual char * GetObjectInfo (Int_t px, Int_t py) const
 Returns string containing info about the object at position (px,py). More...
 
virtual Option_tGetOption () const
 
virtual const char * GetTitle () const
 Returns title of object. More...
 
virtual UInt_t GetUniqueID () const
 Return the unique object id. More...
 
virtual Bool_t HandleTimer (TTimer *timer)
 Execute action in response of a timer timing out. More...
 
virtual ULong_t Hash () const
 Return hash value for this object. More...
 
Bool_t HasInconsistentHash () const
 Return true is the type of this object is known to have an inconsistent setup for Hash and RecursiveRemove (i.e. More...
 
virtual void Info (const char *method, const char *msgfmt,...) const
 Issue info message. More...
 
virtual Bool_t InheritsFrom (const char *classname) const
 Returns kTRUE if object inherits from class "classname". More...
 
virtual Bool_t InheritsFrom (const TClass *cl) const
 Returns kTRUE if object inherits from TClass cl. More...
 
virtual void Inspect () const
 Dump contents of this object in a graphics canvas. More...
 
void InvertBit (UInt_t f)
 
virtual TClassIsA () const
 
virtual Bool_t IsEqual (const TObject *obj) const
 Default equal comparison (objects are equal if they have the same address in memory). More...
 
virtual Bool_t IsFolder () const
 Returns kTRUE in case object contains browsable objects (like containers or lists of other objects). More...
 
R__ALWAYS_INLINE Bool_t IsOnHeap () const
 
virtual Bool_t IsSortable () const
 
R__ALWAYS_INLINE Bool_t IsZombie () const
 
virtual void ls (Option_t *option="") const
 The ls function lists the contents of a class on stdout. More...
 
void MayNotUse (const char *method) const
 Use this method to signal that a method (defined in a base class) may not be called in a derived class (in principle against good design since a child class should not provide less functionality than its parent, however, sometimes it is necessary). More...
 
virtual Bool_t Notify ()
 This method must be overridden to handle object notification. More...
 
void Obsolete (const char *method, const char *asOfVers, const char *removedFromVers) const
 Use this method to declare a method obsolete. More...
 
void operator delete (void *ptr)
 Operator delete. More...
 
void operator delete[] (void *ptr)
 Operator delete []. More...
 
void * operator new (size_t sz)
 
void * operator new (size_t sz, void *vp)
 
void * operator new[] (size_t sz)
 
void * operator new[] (size_t sz, void *vp)
 
TObjectoperator= (const TObject &rhs)
 TObject assignment operator. More...
 
virtual void Paint (Option_t *option="")
 This method must be overridden if a class wants to paint itself. More...
 
virtual void Pop ()
 Pop on object drawn in a pad to the top of the display list. More...
 
virtual void Print (Option_t *option="") const
 This method must be overridden when a class wants to print itself. More...
 
virtual Int_t Read (const char *name)
 Read contents of object with specified name from the current directory. More...
 
virtual void RecursiveRemove (TObject *obj)
 Recursively remove this object from a list. More...
 
void ResetBit (UInt_t f)
 
virtual void SaveAs (const char *filename="", Option_t *option="") const
 Save this object in the file specified by filename. More...
 
virtual void SavePrimitive (std::ostream &out, Option_t *option="")
 Save a primitive as a C++ statement(s) on output stream "out". More...
 
void SetBit (UInt_t f)
 
void SetBit (UInt_t f, Bool_t set)
 Set or unset the user status bits as specified in f. More...
 
virtual void SetDrawOption (Option_t *option="")
 Set drawing option for object. More...
 
virtual void SetUniqueID (UInt_t uid)
 Set the unique object id. More...
 
virtual void Streamer (TBuffer &)
 Stream an object of class TObject. More...
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
virtual void SysError (const char *method, const char *msgfmt,...) const
 Issue system error message. More...
 
R__ALWAYS_INLINE Bool_t TestBit (UInt_t f) const
 
Int_t TestBits (UInt_t f) const
 
virtual void UseCurrentStyle ()
 Set current style settings in this object This function is called when either TCanvas::UseCurrentStyle or TROOT::ForceStyle have been invoked. More...
 
virtual void Warning (const char *method, const char *msgfmt,...) const
 Issue warning message. More...
 
virtual Int_t Write (const char *name=0, Int_t option=0, Int_t bufsize=0)
 Write this object to the current directory. More...
 
virtual Int_t Write (const char *name=0, Int_t option=0, Int_t bufsize=0) const
 Write this object to the current directory. More...
 
- Public Member Functions inherited from RooPrintable
 RooPrintable ()
 
virtual ~RooPrintable ()
 
virtual Int_t defaultPrintContents (Option_t *opt) const
 Default choice of contents to be printed (name and value) More...
 
virtual StyleOption defaultPrintStyle (Option_t *opt) const
 
virtual TClassIsA () const
 
virtual void printAddress (std::ostream &os) const
 Print class name of object. More...
 
virtual void printArgs (std::ostream &os) const
 Interface for printing of object arguments. More...
 
virtual void printClassName (std::ostream &os) const
 Print class name of object. More...
 
virtual void printExtras (std::ostream &os) const
 Interface to print extras of object. More...
 
virtual void printMultiline (std::ostream &os, Int_t contents, bool verbose=false, TString indent="") const
 Interface for detailed printing of object. More...
 
virtual void printName (std::ostream &os) const
 Print name of object. More...
 
virtual void printStream (std::ostream &os, Int_t contents, StyleOption style, TString indent="") const
 Print description of object on ostream, printing contents set by contents integer, which is interpreted as an OR of 'enum ContentsOptions' values and in the style given by 'enum StyleOption'. More...
 
virtual void printTitle (std::ostream &os) const
 Print title of object. More...
 
virtual void printTree (std::ostream &os, TString indent="") const
 Interface for tree structure printing of object. More...
 
virtual void printValue (std::ostream &os) const
 Interface to print value of object. More...
 
virtual void Streamer (TBuffer &)
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 
- Public Member Functions inherited from RooDirItem
 RooDirItem ()
 
 RooDirItem (const RooDirItem &)
 
virtual ~RooDirItem ()
 
virtual TClassIsA () const
 
virtual void Streamer (TBuffer &)
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 

Static Public Member Functions

static TClassClass ()
 
static const char * Class_Name ()
 
static Version_t Class_Version ()
 
static const char * DeclFileName ()
 
static RooFitResultlastMinuitFit (const RooArgList &varList=RooArgList())
 Import the results of the last fit performed by gMinuit, interpreting the fit parameters as the given varList of parameters. More...
 
static RooFitResultprefitResult (const RooArgList &paramList)
 Import the results of the last fit performed by gMinuit, interpreting the fit parameters as the given varList of parameters. More...
 
- Static Public Member Functions inherited from TNamed
static TClassClass ()
 
static const char * Class_Name ()
 
static Version_t Class_Version ()
 
static const char * DeclFileName ()
 
- Static Public Member Functions inherited from TObject
static TClassClass ()
 
static const char * Class_Name ()
 
static Version_t Class_Version ()
 
static const char * DeclFileName ()
 
static Longptr_t GetDtorOnly ()
 Return destructor only flag. More...
 
static Bool_t GetObjectStat ()
 Get status of object stat flag. More...
 
static void SetDtorOnly (void *obj)
 Set destructor only flag. More...
 
static void SetObjectStat (Bool_t stat)
 Turn on/off tracking of objects in the TObjectTable. More...
 
- Static Public Member Functions inherited from RooPrintable
static TClassClass ()
 
static const char * Class_Name ()
 
static Version_t Class_Version ()
 
static const char * DeclFileName ()
 
static std::ostream & defaultPrintStream (std::ostream *os=0)
 Return a reference to the current default stream to use in Print(). More...
 
static void nameFieldLength (Int_t newLen)
 Set length of field reserved from printing name of RooAbsArgs in multi-line collection printing to given amount. More...
 
- Static Public Member Functions inherited from RooDirItem
static TClassClass ()
 
static const char * Class_Name ()
 
static Version_t Class_Version ()
 
static const char * DeclFileName ()
 

Protected Member Functions

double correlation (Int_t row, Int_t col) const
 Return a correlation matrix element addressed with numeric indices. More...
 
double covariance (Int_t row, Int_t col) const
 Return the covariance matrix element addressed with numeric indices. More...
 
void fillCorrMatrix ()
 Internal utility method to extract the correlation matrix and the global correlation coefficients from the MINUIT memory buffer and fill the internal arrays. More...
 
void fillCorrMatrix (const std::vector< double > &globalCC, const TMatrixDSym &corrs, const TMatrixDSym &covs)
 Function called by RooMinimizer. More...
 
void fillLegacyCorrMatrix () const
 Sanity check. More...
 
void fillPrefitCorrMatrix ()
 
void setConstParList (const RooArgList &list)
 Fill the list of constant parameters. More...
 
void setCovarianceMatrix (TMatrixDSym &V)
 Store externally provided correlation matrix in this RooFitResult ;. More...
 
void setCovQual (Int_t val)
 
void setEDM (double val)
 
void setFinalParList (const RooArgList &list)
 Fill the list of final values of the floating parameters. More...
 
void setInitParList (const RooArgList &list)
 Fill the list of initial values of the floating parameters. More...
 
void setMinNLL (double val)
 
void setNumInvalidNLL (Int_t val)
 
void setStatus (Int_t val)
 
void setStatusHistory (std::vector< std::pair< std::string, int > > &hist)
 
- Protected Member Functions inherited from TObject
virtual void DoError (int level, const char *location, const char *fmt, va_list va) const
 Interface to ErrorHandler (protected). More...
 
void MakeZombie ()
 
- Protected Member Functions inherited from RooDirItem
void appendToDir (TObject *obj, bool forceMemoryResident=false)
 Append object to directory. More...
 
void removeFromDir (TObject *obj)
 Remove object from directory it was added to. More...
 

Protected Attributes

TMatrixDSym_CM = nullptr
 Correlation matrix. More...
 
RooArgList_constPars = nullptr
 List of constant parameters. More...
 
TList _corrMatrix
 ! Correlation matrix (list of RooArgLists) More...
 
Int_t _covQual
 MINUIT quality code of covariance matrix. More...
 
double _edm
 Estimated distance to minimum. More...
 
RooArgList_finalPars = nullptr
 List of floating parameters with final values. More...
 
TVectorD_GC = nullptr
 Global correlation coefficients. More...
 
RooArgList_globalCorr = nullptr
 ! List of global correlation coefficients More...
 
RooArgList_initPars = nullptr
 List of floating parameters with initial values. More...
 
TMatrixF_Lt = nullptr
 ! triangular matrix used for generate random perturbations More...
 
double _minNLL
 NLL at minimum. More...
 
Int_t _numBadNLL
 Number calls with bad (zero,negative) likelihood. More...
 
RooArgList_randomPars = nullptr
 ! List of floating parameters with most recent random perturbation applied More...
 
Int_t _status
 MINUIT status code. More...
 
std::vector< std::pair< std::string, int > > _statusHistory
 History of status codes. More...
 
TMatrixDSym_VM = nullptr
 Covariance matrix. More...
 
- Protected Attributes inherited from TNamed
TString fName
 
TString fTitle
 
- Protected Attributes inherited from RooDirItem
TDirectory_dir {nullptr}
 ! Associated directory More...
 

Friends

class RooAbsPdf
 
class RooMinimizer
 
class RooMinuit
 

Additional Inherited Members

- Public Types inherited from TObject
enum  {
  kIsOnHeap = 0x01000000 , kNotDeleted = 0x02000000 , kZombie = 0x04000000 , kInconsistent = 0x08000000 ,
  kBitMask = 0x00ffffff
}
 
enum  { kSingleKey = (1ULL << ( 0 )) , kOverwrite = (1ULL << ( 1 )) , kWriteDelete = (1ULL << ( 2 )) }
 
enum  EDeprecatedStatusBits { kObjInCanvas = (1ULL << ( 3 )) }
 
enum  EStatusBits {
  kCanDelete = (1ULL << ( 0 )) , kMustCleanup = (1ULL << ( 3 )) , kIsReferenced = (1ULL << ( 4 )) , kHasUUID = (1ULL << ( 5 )) ,
  kCannotPick = (1ULL << ( 6 )) , kNoContextMenu = (1ULL << ( 8 )) , kInvalidObject = (1ULL << ( 13 ))
}
 
- Public Types inherited from RooPrintable
enum  ContentsOption {
  kName =1 , kClassName =2 , kValue =4 , kArgs =8 ,
  kExtras =16 , kAddress =32 , kTitle =64 , kCollectionHeader =128
}
 
enum  StyleOption {
  kInline =1 , kSingleLine =2 , kStandard =3 , kVerbose =4 ,
  kTreeStructure =5
}
 
- Protected Types inherited from TObject
enum  { kOnlyPrepStep = (1ULL << ( 3 )) }
 
- Static Protected Attributes inherited from RooPrintable
static Int_t _nameLength
 

#include <RooFitResult.h>

Inheritance diagram for RooFitResult:
[legend]

Constructor & Destructor Documentation

◆ RooFitResult() [1/2]

RooFitResult::RooFitResult ( const char *  name = 0,
const char *  title = 0 
)

Constructor with name and title.

Definition at line 67 of file RooFitResult.cxx.

◆ RooFitResult() [2/2]

RooFitResult::RooFitResult ( const RooFitResult other)

Copy constructor.

Definition at line 78 of file RooFitResult.cxx.

◆ ~RooFitResult()

RooFitResult::~RooFitResult ( )
override

Destructor.

Definition at line 113 of file RooFitResult.cxx.

Member Function Documentation

◆ Class()

static TClass * RooFitResult::Class ( )
static
Returns
TClass describing this class

◆ Class_Name()

static const char * RooFitResult::Class_Name ( )
static
Returns
Name of this class

◆ Class_Version()

static Version_t RooFitResult::Class_Version ( )
inlinestatic
Returns
Version of this class

Definition at line 204 of file RooFitResult.h.

◆ clone()

virtual TObject * RooFitResult::clone ( ) const
inlinevirtual

Definition at line 51 of file RooFitResult.h.

◆ Clone()

TObject * RooFitResult::Clone ( const char *  newname = 0) const
inlineoverridevirtual

Make a clone of an object using the Streamer facility.

If newname is specified, this will be the name of the new object.

Reimplemented from TNamed.

Definition at line 46 of file RooFitResult.h.

◆ conditionalCovarianceMatrix()

TMatrixDSym RooFitResult::conditionalCovarianceMatrix ( const RooArgList params) const

Return a reduced covariance matrix, which is calculated as.

\[ V_\mathrm{red} = \bar{V_{22}} = V_{11} - V_{12} \cdot V_{22}^{-1} \cdot V_{21}, \]

where \( V_{11},V_{12},V_{21},V_{22} \) represent a block decomposition of the covariance matrix into observables that are propagated (labeled by index '1') and that are not propagated (labeled by index '2'), and \( \bar{V_{22}} \) is the Shur complement of \( V_{22} \), calculated as shown above.

(Note that \( V_\mathrm{red} \) is not a simple sub-matrix of \( V \))

Definition at line 1154 of file RooFitResult.cxx.

◆ constPars()

const RooArgList & RooFitResult::constPars ( ) const
inline

Return list of constant parameters.

Definition at line 103 of file RooFitResult.h.

◆ correlation() [1/5]

const RooArgList * RooFitResult::correlation ( const char *  parname) const

Return the set of correlation coefficients of parameter 'par' with all other floating parameters.

Definition at line 406 of file RooFitResult.cxx.

◆ correlation() [2/5]

double RooFitResult::correlation ( const char *  parname1,
const char *  parname2 
) const

Return the correlation between parameters 'par1' and 'par2'.

Definition at line 385 of file RooFitResult.cxx.

◆ correlation() [3/5]

const RooArgList * RooFitResult::correlation ( const RooAbsArg par) const
inline

Return pointer to list of correlations of all parameters with par.

Definition at line 122 of file RooFitResult.h.

◆ correlation() [4/5]

double RooFitResult::correlation ( const RooAbsArg par1,
const RooAbsArg par2 
) const
inline

Return correlation between par1 and par2.

Definition at line 118 of file RooFitResult.h.

◆ correlation() [5/5]

double RooFitResult::correlation ( Int_t  row,
Int_t  col 
) const
protected

Return a correlation matrix element addressed with numeric indices.

Definition at line 463 of file RooFitResult.cxx.

◆ correlationHist()

TH2 * RooFitResult::correlationHist ( const char *  name = "correlation_matrix") const

Return TH2D of correlation matrix.

Definition at line 1070 of file RooFitResult.cxx.

◆ correlationMatrix()

const TMatrixDSym & RooFitResult::correlationMatrix ( ) const

Return correlation matrix ;.

Definition at line 1230 of file RooFitResult.cxx.

◆ covariance()

double RooFitResult::covariance ( Int_t  row,
Int_t  col 
) const
protected

Return the covariance matrix element addressed with numeric indices.

Definition at line 472 of file RooFitResult.cxx.

◆ covarianceMatrix()

const TMatrixDSym & RooFitResult::covarianceMatrix ( ) const

Return covariance matrix.

Definition at line 1096 of file RooFitResult.cxx.

◆ covQual()

Int_t RooFitResult::covQual ( ) const
inline

Return MINUIT quality code of covariance matrix.

Definition at line 87 of file RooFitResult.h.

◆ createHessePdf()

RooAbsPdf * RooFitResult::createHessePdf ( const RooArgSet params) const

Return a p.d.f that represents the fit result as a multi-variate probability densisty function on the floating fit parameters, including correlations.

Definition at line 1241 of file RooFitResult.cxx.

◆ DeclFileName()

static const char * RooFitResult::DeclFileName ( )
inlinestatic
Returns
Name of the file containing the class declaration

Definition at line 204 of file RooFitResult.h.

◆ defaultPrintContents()

Int_t RooFitResult::defaultPrintContents ( Option_t opt) const
overridevirtual

Configure default contents to be printed.

Reimplemented from RooPrintable.

Definition at line 1415 of file RooFitResult.cxx.

◆ defaultPrintStyle()

RooPrintable::StyleOption RooFitResult::defaultPrintStyle ( Option_t opt) const
overridevirtual

Configure mapping of Print() arguments to RooPrintable print styles.

Reimplemented from RooPrintable.

Definition at line 1424 of file RooFitResult.cxx.

◆ edm()

double RooFitResult::edm ( ) const
inline

Return estimated distance to minimum.

Definition at line 95 of file RooFitResult.h.

◆ fillCorrMatrix() [1/2]

void RooFitResult::fillCorrMatrix ( )
protected

Internal utility method to extract the correlation matrix and the global correlation coefficients from the MINUIT memory buffer and fill the internal arrays.

Definition at line 683 of file RooFitResult.cxx.

◆ fillCorrMatrix() [2/2]

void RooFitResult::fillCorrMatrix ( const std::vector< double > &  globalCC,
const TMatrixDSym corrs,
const TMatrixDSym covs 
)
protected

Function called by RooMinimizer.

Definition at line 579 of file RooFitResult.cxx.

◆ fillLegacyCorrMatrix()

void RooFitResult::fillLegacyCorrMatrix ( ) const
protected

Sanity check.

Definition at line 614 of file RooFitResult.cxx.

◆ fillPrefitCorrMatrix()

void RooFitResult::fillPrefitCorrMatrix ( )
protected

Definition at line 739 of file RooFitResult.cxx.

◆ floatParsFinal()

const RooArgList & RooFitResult::floatParsFinal ( ) const
inline

Return list of floating parameters after fit.

Definition at line 111 of file RooFitResult.h.

◆ floatParsInit()

const RooArgList & RooFitResult::floatParsInit ( ) const
inline

Return list of floating parameters before fit.

Definition at line 107 of file RooFitResult.h.

◆ globalCorr() [1/3]

const RooArgList * RooFitResult::globalCorr ( )

Return the list of all global correlations.

Definition at line 449 of file RooFitResult.cxx.

◆ globalCorr() [2/3]

double RooFitResult::globalCorr ( const char *  parname)

Return the global correlation of the named parameter.

Definition at line 425 of file RooFitResult.cxx.

◆ globalCorr() [3/3]

double RooFitResult::globalCorr ( const RooAbsArg par)
inline

Definition at line 137 of file RooFitResult.h.

◆ IsA()

TClass * RooFitResult::IsA ( ) const
inlineoverridevirtual
Returns
TClass describing current object

Reimplemented from TNamed.

Definition at line 204 of file RooFitResult.h.

◆ isIdentical()

bool RooFitResult::isIdentical ( const RooFitResult other,
double  tol = 1e-6,
double  tolCorr = 1e-4,
bool  verbose = true 
) const

Return true if this fit result is identical to other within tolerances.

Parameters
[in]otherFit result to test against.
[in]tolRelative tolerance for parameters and NLL.
[in]tolCorrabsolute tolerance for correlation coefficients.
[in]verboseIf this function will log to the standard output when comparisions fail.

As the relative tolerance for the parameter errors, the default value of 1e-3 will be used.

Definition at line 851 of file RooFitResult.cxx.

◆ isIdenticalNoCov()

bool RooFitResult::isIdenticalNoCov ( const RooFitResult other,
double  tol = 1e-6,
double  tolErr = 1e-3,
bool  verbose = true 
) const

Return true if this fit result is identical to other within tolerances, ignoring the correlation matrix.

Parameters
[in]otherFit result to test against.
[in]tolRelative tolerance for parameters and NLL.
[in]tolErrRelative tolerance for parameter errors.
[in]verboseIf this function will log to the standard output when comparisions fail.

Definition at line 789 of file RooFitResult.cxx.

◆ lastMinuitFit()

RooFitResult * RooFitResult::lastMinuitFit ( const RooArgList varList = RooArgList())
static

Import the results of the last fit performed by gMinuit, interpreting the fit parameters as the given varList of parameters.

Definition at line 905 of file RooFitResult.cxx.

◆ minNll()

double RooFitResult::minNll ( ) const
inline

Return minimized -log(L) value.

Definition at line 99 of file RooFitResult.h.

◆ numInvalidNLL()

Int_t RooFitResult::numInvalidNLL ( ) const
inline

Return number of NLL evaluations with problems.

Definition at line 91 of file RooFitResult.h.

◆ numStatusHistory()

UInt_t RooFitResult::numStatusHistory ( ) const
inline

Definition at line 82 of file RooFitResult.h.

◆ plotOn() [1/2]

RooPlot * RooFitResult::plotOn ( RooPlot frame,
const RooAbsArg par1,
const RooAbsArg par2,
const char *  options = "ME" 
) const
inline

Add objects to a 2D plot.

Plot error ellipse in par1 and par2 on frame.

Definition at line 144 of file RooFitResult.h.

◆ plotOn() [2/2]

RooPlot * RooFitResult::plotOn ( RooPlot frame,
const char *  parName1,
const char *  parName2,
const char *  options = "ME" 
) const

Add objects to a 2D plot that represent the fit results for the two named parameters.

The input frame with the objects added is returned, or zero in case of an error. Which objects are added are determined by the options string which should be a concatenation of the following (not case sensitive):

  • M - a marker at the best fit result
  • E - an error ellipse calculated at 1-sigma using the error matrix at the minimum
  • 1 - the 1-sigma error bar for parameter 1
  • 2 - the 1-sigma error bar for parameter 2
  • B - the bounding box for the error ellipse
  • H - a line and horizontal axis for reading off the correlation coefficient
  • V - a line and vertical axis for reading off the correlation coefficient
  • A - draw axes for reading off the correlation coefficients with the H or V options

You can change the attributes of objects in the returned RooPlot using the various RooPlot::getAttXxx(name) member functions, e.g.

plot->getAttLine("contour")->SetLineStyle(kDashed);
@ kDashed
Definition: TAttLine.h:48
winID h TVirtualViewer3D TVirtualGLPainter char TVirtualGLPainter plot

Use plot->Print() for a list of all objects and their names (unfortunately most of the ROOT builtin graphics objects like TLine are unnamed). Drag the left mouse button along the labels of either axis button to interactively zoom in a plot.

Definition at line 234 of file RooFitResult.cxx.

◆ prefitResult()

RooFitResult * RooFitResult::prefitResult ( const RooArgList paramList)
static

Import the results of the last fit performed by gMinuit, interpreting the fit parameters as the given varList of parameters.

Definition at line 995 of file RooFitResult.cxx.

◆ Print()

void RooFitResult::Print ( Option_t option = 0) const
inlineoverridevirtual

Print TNamed name and title.

Reimplemented from TNamed.

Definition at line 66 of file RooFitResult.h.

◆ printArgs()

void RooFitResult::printArgs ( std::ostream &  os) const
overridevirtual

Print arguments of fit result, i.e. the parameters of the fit.

Reimplemented from RooPrintable.

Definition at line 1396 of file RooFitResult.cxx.

◆ printClassName()

void RooFitResult::printClassName ( std::ostream &  os) const
overridevirtual

Print class name of fit result.

Reimplemented from RooPrintable.

Definition at line 1387 of file RooFitResult.cxx.

◆ printMultiline()

void RooFitResult::printMultiline ( std::ostream &  os,
Int_t  contents,
bool  verbose = false,
TString  indent = "" 
) const
overridevirtual

Print fit result to stream 'os'.

In Verbose mode, the constant parameters and the initial and final values of the floating parameters are printed. Standard mode only the final values of the floating parameters are printed

Reimplemented from RooPrintable.

Definition at line 484 of file RooFitResult.cxx.

◆ printName()

void RooFitResult::printName ( std::ostream &  os) const
overridevirtual

Print name of fit result.

Reimplemented from RooPrintable.

Definition at line 1369 of file RooFitResult.cxx.

◆ printTitle()

void RooFitResult::printTitle ( std::ostream &  os) const
overridevirtual

Print title of fit result.

Reimplemented from RooPrintable.

Definition at line 1378 of file RooFitResult.cxx.

◆ printValue()

void RooFitResult::printValue ( std::ostream &  os) const
overridevirtual

Print the value of the fit result, i.e.g the status, minimized FCN, edm and covariance quality code.

Reimplemented from RooPrintable.

Definition at line 1406 of file RooFitResult.cxx.

◆ randomizePars()

const RooArgList & RooFitResult::randomizePars ( ) const

Generate random perturbations of the final parameters using the covariance matrix.

Return a list of floating parameter values that are perturbed from the final fit values by random amounts sampled from the covariance matrix.

The returned object is overwritten with each call and belongs to the RooFitResult. Uses the "square root method" to decompose the covariance matrix, which makes inverting it unnecessary.

Definition at line 332 of file RooFitResult.cxx.

◆ reducedCovarianceMatrix()

TMatrixDSym RooFitResult::reducedCovarianceMatrix ( const RooArgList params) const

Return a reduced covariance matrix (Note that Vred is a simple sub-matrix of V, row/columns are ordered to matched the convention given in input argument 'params'.

Definition at line 1108 of file RooFitResult.cxx.

◆ setConstParList()

void RooFitResult::setConstParList ( const RooArgList list)
protected

Fill the list of constant parameters.

Definition at line 135 of file RooFitResult.cxx.

◆ setCovarianceMatrix()

void RooFitResult::setCovarianceMatrix ( TMatrixDSym V)
protected

Store externally provided correlation matrix in this RooFitResult ;.

Definition at line 1036 of file RooFitResult.cxx.

◆ setCovQual()

void RooFitResult::setCovQual ( Int_t  val)
inlineprotected

Definition at line 172 of file RooFitResult.h.

◆ setEDM()

void RooFitResult::setEDM ( double  val)
inlineprotected

Definition at line 170 of file RooFitResult.h.

◆ setFinalParList()

void RooFitResult::setFinalParList ( const RooArgList list)
protected

Fill the list of final values of the floating parameters.

Definition at line 167 of file RooFitResult.cxx.

◆ setInitParList()

void RooFitResult::setInitParList ( const RooArgList list)
protected

Fill the list of initial values of the floating parameters.

Definition at line 151 of file RooFitResult.cxx.

◆ setMinNLL()

void RooFitResult::setMinNLL ( double  val)
inlineprotected

Definition at line 169 of file RooFitResult.h.

◆ SetName()

void RooFitResult::SetName ( const char *  name)
overridevirtual

Change name of RooFitResult object.

Reimplemented from TNamed.

Definition at line 1347 of file RooFitResult.cxx.

◆ SetNameTitle()

void RooFitResult::SetNameTitle ( const char *  name,
const char *  title 
)
overridevirtual

Change name and title of RooFitResult object.

Reimplemented from TNamed.

Definition at line 1358 of file RooFitResult.cxx.

◆ setNumInvalidNLL()

void RooFitResult::setNumInvalidNLL ( Int_t  val)
inlineprotected

Definition at line 173 of file RooFitResult.h.

◆ setStatus()

void RooFitResult::setStatus ( Int_t  val)
inlineprotected

Definition at line 171 of file RooFitResult.h.

◆ setStatusHistory()

void RooFitResult::setStatusHistory ( std::vector< std::pair< std::string, int > > &  hist)
inlineprotected

Definition at line 178 of file RooFitResult.h.

◆ status()

Int_t RooFitResult::status ( ) const
inline

Return MINUIT status code.

Definition at line 78 of file RooFitResult.h.

◆ statusCodeHistory()

Int_t RooFitResult::statusCodeHistory ( UInt_t  icycle) const

Definition at line 183 of file RooFitResult.cxx.

◆ statusLabelHistory()

const char * RooFitResult::statusLabelHistory ( UInt_t  icycle) const

Definition at line 197 of file RooFitResult.cxx.

◆ Streamer()

void RooFitResult::Streamer ( TBuffer R__b)
overridevirtual

Stream an object of class RooFitResult.

Reimplemented from TNamed.

Definition at line 1436 of file RooFitResult.cxx.

◆ StreamerNVirtual()

void RooFitResult::StreamerNVirtual ( TBuffer ClassDef_StreamerNVirtual_b)
inline

Definition at line 204 of file RooFitResult.h.

Friends And Related Function Documentation

◆ RooAbsPdf

friend class RooAbsPdf
friend

Definition at line 162 of file RooFitResult.h.

◆ RooMinimizer

friend class RooMinimizer
friend

Definition at line 164 of file RooFitResult.h.

◆ RooMinuit

friend class RooMinuit
friend

Definition at line 163 of file RooFitResult.h.

Member Data Documentation

◆ _CM

TMatrixDSym* RooFitResult::_CM = nullptr
protected

Correlation matrix.

Definition at line 198 of file RooFitResult.h.

◆ _constPars

RooArgList* RooFitResult::_constPars = nullptr
protected

List of constant parameters.

Definition at line 188 of file RooFitResult.h.

◆ _corrMatrix

TList RooFitResult::_corrMatrix
mutableprotected

! Correlation matrix (list of RooArgLists)

Definition at line 193 of file RooFitResult.h.

◆ _covQual

Int_t RooFitResult::_covQual
protected

MINUIT quality code of covariance matrix.

Definition at line 184 of file RooFitResult.h.

◆ _edm

double RooFitResult::_edm
protected

Estimated distance to minimum.

Definition at line 187 of file RooFitResult.h.

◆ _finalPars

RooArgList* RooFitResult::_finalPars = nullptr
protected

List of floating parameters with final values.

Definition at line 190 of file RooFitResult.h.

◆ _GC

TVectorD* RooFitResult::_GC = nullptr
protected

Global correlation coefficients.

Definition at line 200 of file RooFitResult.h.

◆ _globalCorr

RooArgList* RooFitResult::_globalCorr = nullptr
mutableprotected

! List of global correlation coefficients

Definition at line 192 of file RooFitResult.h.

◆ _initPars

RooArgList* RooFitResult::_initPars = nullptr
protected

List of floating parameters with initial values.

Definition at line 189 of file RooFitResult.h.

◆ _Lt

TMatrixF* RooFitResult::_Lt = nullptr
mutableprotected

! triangular matrix used for generate random perturbations

Definition at line 196 of file RooFitResult.h.

◆ _minNLL

double RooFitResult::_minNLL
protected

NLL at minimum.

Definition at line 186 of file RooFitResult.h.

◆ _numBadNLL

Int_t RooFitResult::_numBadNLL
protected

Number calls with bad (zero,negative) likelihood.

Definition at line 185 of file RooFitResult.h.

◆ _randomPars

RooArgList* RooFitResult::_randomPars = nullptr
mutableprotected

! List of floating parameters with most recent random perturbation applied

Definition at line 195 of file RooFitResult.h.

◆ _status

Int_t RooFitResult::_status
protected

MINUIT status code.

Definition at line 183 of file RooFitResult.h.

◆ _statusHistory

std::vector<std::pair<std::string,int> > RooFitResult::_statusHistory
protected

History of status codes.

Definition at line 202 of file RooFitResult.h.

◆ _VM

TMatrixDSym* RooFitResult::_VM = nullptr
protected

Covariance matrix.

Definition at line 199 of file RooFitResult.h.

Libraries for RooFitResult:
[legend]

The documentation for this class was generated from the following files: