Hi,
I got a weird problem that when I use RooDataSet to load a tree, all branch of all events are the same (0 or center of the RooRealvar range), not correctly imported.
TFile *fin=TFile::Open(“fnew.root”);
TTree tMuMu=(TTree)fin->Get(“DiMuTree”);
RooRealVar SMuMu_mass(“SMuMu_mass”,“SMuMu_mass”,60,120);
RooRealVar SMuMu_pt(“SMuMu_pt”,“SMuMu_pt”,0);
RooRealVar SMuMu_phi(“SMuMu_phi”,“SMuMu_phi”,0);
RooRealVar SMuMu_eta(“SMuMu_eta”,“SMuMu_eta”,0);
RooDataSet RooDS_All(“RooDS_All”,“RooDS_All”,RooArgSet(SMuMu_mass,SMuMu_pt,SMuMu_phi,SMuMu_eta),Import(*tMuMu));
Tree content
SMuMu distribution plotted from tree
SMuMu distribution plotted from RooDataSet