RooFit and vectors of numbers, how to

Dear ROOT Support,
I would like to use RooFit for my analysis and I’m relatively new with this component of ROOT.

I realized that RooFit is not able to read branches of a TTree that are of the kind: std::vector
Therefore, since I can not change the type of my TTree branches, I would like to load "by hand"
the numbers that are in the TTree branches into RooFit variables.

I have no idea how to do this.

All the doc I’ve seen around do not explain how to “fill”, number by number, a RooFit variable. They all show examples where the RooArgSet are read automatically from a file.

I hope the explanation of my problem is clear: I would like to compose a kind of vector of numbers to be fitted with RooFit methods. But I would like to give the numbers to the vector “by hand”, meaning one by one, for example in a for loop.

Thank you very much.

  • Mauro.