Storing a RooDataSet in a TTree

Dear ROOT experts,

I am trying to store a RooDataSet in a TTree. More precisesely I am reading in a TTree then perform a sPlot and want to store the new RooDataSet with the weights in a new Tree and save that into a .root file.

I have a working example for doing this up until 5.32.00. What I did is:

I found in the release notes of 5.32.00 that the internal storage structure of RooDataSets was changed from RooTreeDataStore to RooVectorDataStore. Is there any possibility to get a TTree out of a RooVectorDataStore object?

All of these objects like RooDataSet, RooVectorDataStore, RooAbsDataStore, etc. have the method tree() but it only returns a NULL pointer.

Thanks for your help

1 Like