Skip to content

Commit

Permalink
Use RooDataSet constructor that takes RooFit::WeightVar argument
Browse files Browse the repository at this point in the history
The constructor that just takes a string is deprecated and will be
removed in ROOT 6.34.
  • Loading branch information
guitargeek committed Oct 2, 2024
1 parent 6cf6c02 commit a5243c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/ShapeTools.py
Original file line number Diff line number Diff line change
Expand Up @@ -1224,7 +1224,7 @@ def shape2Data(self, shape, channel, process, _cache={}):
_cache[name] = rdh
else:
obs.add(self.out.var("CMS_fakeWeight"))
rds = ROOT.RooDataSet(name, name, obs, "CMS_fakeWeight")
rds = ROOT.RooDataSet(name, name, obs, ROOT.RooFit.WeightVar("CMS_fakeWeight"))
obs.setRealValue("CMS_fakeWeight", self.DC.obs[channel])
rds.add(obs, self.DC.obs[channel])
_cache[name] = rds
Expand Down

0 comments on commit a5243c4

Please sign in to comment.