Superimpose TProfile form TH2::ProfileY on TH2

Hello,

I’d like to superimpose on a TH2F the result of TH2F::ProfileY(). Since the TProfile x axis is the TH2F y axis, TProfile::Draw(“same”) does not work. What is the easiest way to achieve that?

                                                      Thanks and ciao

                                                              Andrea

You mean you need to invert the X and Y axis ? We do not have many options doing that.
Try HBAR: root.cern.ch/root/html/THistPainter.html#HP10

Thanks,

hbar is exactly the option I would need but when superimposed to the TH2 the results are “ugly”. Clearly markers would be much better. So I can only suggest you to consider adding this option in future as a natural consequence of TH2::ProfileY

                                                   Thanks and ciao

                                                          Andrea

Yes that’s what I would have suspected (that you prefer markers).
Right now there is no way to invert the 2 axis except with Hbar.
To to that right now the best would be to use intermediate TGraph