However, neither I am able to see the correct distribution as expected from the data nor the fit.
Can you please help? This is my first time with RooFit!
I think I have made some progress in fitting gaussian convoluted exponential to the data
[test.txt (10.0 KB)] using the modified
the version of the earlier code which is [gexp_conv.C (2.8 KB)].
However, the fit is still very poor. It would be of great help you could guide me on how to improve the fit.
thanks for following up and sorry for the late reply!
The problem with your fit is that the model is not appropriate for your data, at least with how the exponential is defined in RooFit. A RooExponential has no boundaries, so it is increasing to the left forever. This can’t fit your data.
Another RooFit user worked around this by multiplying the exponential with a step function before the convolution:
I have adapted your script to do this too, and also improved the parameter boundaries a bit. The fit now looks like this: gexp_conv.C (3.0 KB)