so now i am drawing histograms in a divided canvas. I think i can access the statbox in a way that similar to ROOT: TPaveStats Class Reference. But It turns out that the codes is trying to access a null pointer. i dont quite understand why it can work in a single plot as in the link but not in the divided canvas. Any suggestion ?
ROOT.gStyle.SetTitleX(0.1)
c = ROOT.TCanvas("c","average acceptance",3600,2400)
c.Divide(6,4)
for i in range(24):
csub = c.cd(i+1)
h = array_of_hs[i]
h.Draw("colz")
ROOT.gPad.Update()
st = h.FindObject("stats")
st.SetX1NDC(0.78)
st.SetY1NDC(0.78)
st.SetX2NDC(0.92)
st.SetY2NDC(0.95)
c.Draw()
_ROOT Version: 6.26 (conda)
_Platform: ubuntu 20.02 (wsl)
Compiler: gcc9