Compare trees in two different files with same structure


I would like to compare value by value two trees which have the same number of entries. I’m sure that’s possible without writing loops etc.

According to the documentation it can be done with AddFriends. However, it doesn’t seem to work as the variables I want to compare have the same name. In /afs/ my attempt is shown.

What am I doing wrong? I’m using Root Version 5.10.


When calling tree.AddFriend, give an alias to your Tree.
See documentation of TTree::addFriend


Ok, I see. It works now. Thanks for the hint! Cheers, Florian :smiley: