Fitting Problem

Dear Rooters,

I’m trying to fit a 1-dim histogram stored in a ROOT file with a user-defined function according to … ata-points web page but it always produce

Detaching from program: /proc/2385/exe, process 2385
Root > Function fitExample() busy flag cleared


I have attached the macro and root file.

So, could you please help me to find where the problem is.

Thank you in advance,

Best regards,



in your macro define the main function fitExample as:

void fitExample() { 



In addition you have other errors, attached is an updated working version

fitExample.C (1.05 KB)

Dear Lorenzo,

Thank you very much for the corrections of my macro.

Kind regards,