Re: [ROOT] AddFriend and MakeClass

From: Rene Brun (Rene.Brun@cern.ch)
Date: Tue Oct 09 2001 - 21:27:44 MEST


Hi Yann,

You should run MakeClass on your main Tree (eg "main") and also
on your "friend Tree. Then, modify the event loop in "main" to read
"friend" in parallel.

It is clearly slightly more complex than using TTree::Draw, but doable.

Rene Brun

On Tue, 9 Oct 2001, Yann Coadou wrote:

> Hi,
> 
> I want to use a class generated by MakeClass to loop over a tree and a
> friend. I have found some information about this at:
> http://root.cern.ch/root/roottalk/roottalk01/1749.html
> Unfortunately this seems to work only if the friend has the same structure
> as the original tree. Is there a trick to make it work when variables in
> the friend do not exist in the original tree? In other words can I get the
> same flexibility with MakeClass as with Draw, ie that variables in the
> friend seem to be in the original file?
> 
> Thanks,
> 
> /Yann
> 
> +------------------------------------------------------------------+
> | Yann Coadou   Fermilab MS 357, PO Box 500, Batavia IL 60510, USA |
> | phone: +1.630.840 5400 fax: +1.630.840 6650 email: yann@fnal.gov |
> +- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
> | Uppsala University        Department of Radiation Sciences (ISV) |
> | PO Box 535, 751 21 Uppsala, Sweden       Phone: +46.18.471 58 27 |
> +------------------------------------------------------------------+
> 



This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:51:02 MET