[ROOT] How to add someting in status box ?

From: Datao Gong (dtgong@physics.umn.edu)
Date: Sun Apr 18 2004 - 02:51:48 MEST

I want to fit histogram with likelihood mode. So i need to access the
likelihood value and put it in the status box.
So write this piece of code in my scripts:
   m_hist->Fit(FunName,"L");   //fit with likelihood mode
   TVirtualFitter *fitter = TVirtualFitter::Fitter(m_hist);
   Double_t amin,edm,errdef;
   Int_t nvpar,nparx;
   fitter->GetStats(amin,edm,errdef,nvpar,nparx); //get 2*(log likelihood)

// get status box
   TPaveStats *st =

    Char_t strll[100];
    TLine *l = st->AddLine(0,0,0,0);
    st->AddText(strll); //add text to status box.

But i found the pointer st is null pointer. Why? How could i fix the


Gong Datao

This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:07 MET