I have generated a 2D RooHistPdf which I am trying to check if it has formed as I expected it to.
(Sorry for using postscript files)
When I observe the 2D distribution, it looks acceptable, as seen here: 2dhist.ps (622 KB).
I hope you would agree that the distribution drops off, but you can see on the xi axis that as the momentum increases, there are still contributions to the xi distribution around the edges.
This is the same 2D histogram rotated to the face the xi plane: 2dhist_xi_face.ps (594 KB).
The point of including this plot is for the following, which is a RooPlot I created which should be projecting the histogram onto the xi plane: projected_xi.ps (9.33 KB)
I know that this distribution should look like this:actual_xi.ps (9.8 KB) although this is not scaled to unity.
Therefore my question is whether there is a bug in the RooPlot feature of RooHistPdf, or if when I define a RooPlot for a 2D distribution, I need to specify how “deep” that projection needs to be, because if you compare the projected_xi.ps and the 2dhist_xi_face.ps, you can see that the shape appears to be as if instead of summing the projected distribution, it has instead scanned this surface for the maximum points in each bin and plotted them.
If someone could provide some guidance here, it would be great, because as I said, it looks as if my 2D pdf is correct (according to my expectations) but my cross-check does not seem to agree.