I am trying to plot on the existing plot the difference between the fitted function and the histogram. I thought it was as simple as including the line h->Add(g,-1); but then my existing plot gets distorted. The macro works fine up until that line. I am very confused and any help would be greatly appreciated. comp.cxx (1013 Bytes) Compton.txt (329.3 KB)
_ROOT Version: 6.23/01
Yes, using the TRatioPlot as shown above it is the correct way for plotting the fit residuals.
If you have any issues using TRatioPlot please let us know