In my macro for stacking histograms, I can change the range of x-axis as I want to, but cannot do the same for Y axis. The upper limit of the histogram is around 6, but the peak of the distribution is slightly over 10. I tried every option for Yaxis range mentioned in this forum but nothing changes.
The simplified macro, input and output root files are attached. Could you help me on this issue?
root [0] .x 50PU_stack.C
Error: Symbol sgnl5top is not defined in current scope 50PU_stack.C:29:
Error: Failed to evaluate sgnl5top->Get("hMET2")
Error: Illegal Assignment to an undeclared symbol MET2_50PU_TDR5 50PU_stack.C:29:
*** Interpreter error recovered ***
root [1]
root [0] .x 50PU_stack.C
SysError in <TFile::TFile>: file stacked_plots/stack_MET2_50PU.root can not be opened (No such file or directory)
Warning in <TFile::Write>: file stacked_plots/stack_MET2_50PU.root not opened in write mode
root [1]