Put Branch inside folder

Dear pyROOTers,

Is it possible to put a branch inside a folder, I know that I can put a tree inside a folder like:

tree = ROOT.TTree('tree','/folder')

and the result tree will be in /folder. How to add a branch ‘br’ inside a ‘folder’, so it can be seen as folder.br

thank you so much

and the result tree will be in /folder

This seems inaccurate. Where did you notice this? (So that we can review this documentation and clarify if need be).

In the notation you mention, the ‘folder’ refers to a TFolder object. When you call

tree = ROOT.TTree('tree','/folder')

a TTree will be created base on the content of the TFolder. To have branch named folder.br, you need to add the corresponding object to the TFolder.


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.