使用Root Root从根中重新介绍TH2直方图,然后用Matplotlib绘制它
我能够使用h = f [...]。to_numpy()
upot的h = f [...]。 然后,我可以将MPLHEP绘制为
hist2dplot(h)
。
但是,我有一个问题要重新替换原始直方图,然后绘制此问题。我找不到使用MPLHEP重新融资的工作示例(我能理解的),我找不到任何这样的方法可以在霸王中进行。
我尝试通过重新序列/重塑阵列来执行此操作,但是随后我再次坚持如何绘制它。
你怎么做?有简单的方法吗?任何提示都受到欢迎:)
I am able to extract a TH2 histogram from ROOT using the h = f[...].to_numpy()
of uproot.
This I can then plot with mplhep as a hist2dplot(h)
.
However, I have the problem that I would like to rebin the original histogram and then plot this. I could not find a working example of rebinning (that I can understand) with mplhep and I cannot find any such way to do it in uproot.
I tried doing this with rebinning/reshaping the arrays, but then I am again stuck at how to plot this exactly.
How do you do it? Is there an easy way? Any hints are welcomed :)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论