ROOT 6 cannot properly retrieve TF1 parameters' names

I’ve got my hands on a root file created by ROOT 5 (v5-34-00-patches). In this file, there are many 1D histograms, each of them was fitted with some user’s “f” function (this was a python function).
When I open this file with ROOT 5, in the TBrowser, I can draw these histograms and I get proper names and values for all function’s parameters (in the statistics box).
However, in ROOT 6 (6.12/06), instead of proper parameters’ names, I get “p0”, “p1”, … displayed (the values are displayed fine).
Also, when I try SomeHisto->GetFunction("f")->Print();, in ROOT 5, I get the full dump with all parameters properly displayed, while in ROOT 6, I only get one line saying “Interpreted based function: f(double *x, double *p). Ndim = 1, Npar = 8” and nothing else (i.e. I do not even get the values of parameters printed).
Could you, please, fix both problems.

Are you able/allowed to share the file?

Attached below is a file with a single histogram (a copy made by ROOT 5).

BTW. I discovered another problem. I tried to copy this histogram using “rootcp” (from ROOT 6.12/06) and I found that the newly produced file can be read by ROOT 6 (it still cannot dump function’s parameters) but it cannot properly be read by ROOT 5:

[...]$ root JustOneHistogram.root
root [0] 
Attaching file JustOneHistogram.root as _file0...
Warning in <TClass::TClass>: no dictionary for class TF1Parameters is available
root [1] h->GetFunction("f")->Print()
Warning in <TStreamerInfo::BuildOld>: Cannot convert TF1::fParErrors from type:vector<double> to type:Double_t*, skip element
Warning in <TStreamerInfo::BuildOld>: Cannot convert TF1::fParMin from type:vector<double> to type:Double_t*, skip element
Warning in <TStreamerInfo::BuildOld>: Cannot convert TF1::fParMax from type:vector<double> to type:Double_t*, skip element
Warning in <TStreamerInfo::BuildOld>: Cannot convert TF1::fSave from type:vector<double> to type:Double_t*, skip element
Warning in <TStreamerInfo::BuildOld>: Cannot convert TF1::fParams from type:TF1Parameters* to type:Double_t*, skip element
                    f : f Ndim= 1, Npar= 8, Noper= 0

JustOneHistogram.root (8.0 KB)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.