Hi all,
I am using RooFit for fitting. So, after fitting I am saving my model as
hist = model_WJets.createHistogram(rrv_mass_lvj.GetName(),4)
hist.SaveAs("wjetmodel.root")
So, somehow it does not takes the normalization. So, to get the original shape of my model I scale this histogram but scaling this histogram it also scales the error bars. I am doing it like below:
Wjet_file = r.TFile.Open("wjetmodel.root")
Wjet_hist = Wjet_file.Get("model_WJets0_xww_sb_lo_from_fitting_em_mlvj__rrv_mass_lvj")
Wjet_hist.Sumw2()
Wjet_hist.SetMarkerColor(3)
Wjet_hist.SetLineColor(3)
Wjet_hist.SetLineWidth(3)
Wjet_hist.SetMarkerSize(1)
Wjet_hist.Scale(501.911)
Wjet_hist.Draw()
Please let me know how I can fix this.
Also, please let me know how I can save histogram from RooFit model including the normalization factor.
with regards,
Ram