_ROOT Version:6.14/08
_Platform:cernVM Compiler: Not Provided
Hi!
I’m trying to create a graph with a couple of fits, using the attached macro. I am trying to get the result of my fits to appear on the graph (The value/error of parameters, etc). I am trying to use TFitResultPtr to show the results of the fit, but there only seems to be a method for printing the results, Print(); , and no way to store the results to a string so that I can put it on the graph (Perhaps using the TPaveText method).
Thanks Stefano!
It is a shame that there isn’t some function to put all of the results of fit onto a graph, especially since parameters are shown automatically in a histogram. However, this will have to do, it doesn’t require that much more effort to put each parameter one by one to the graph, eh?
I actually tried this already before I posted. If I add the SetOptFit statement at the beginning of the “analysis” method, then the output remains unchanged. It would seem that this statement only works if a histogram (such as TH1F) is being fitted. Then the SetOptFit statement works. However, for a TGraph, it appears to do nothing.
-T