is there a way to write an array of objects (of length N) to a single Branch of a TTree without creating N different sub-branches?
In other words, I would like to obtain something like this:
myTree->Branch(“myBranch”, thePointer, “myBranch[32]/D”); //this creates a new branch containing an array of 32 Double_t
Where rather than an array of Double_t I would like to have an array of a certain object.
In general, I think, you will need to “encapsulate” your “myBranch[32]” into some another class (and then create the tree branch for an object of this class).