Re: [ROOT] TFX - suggestion

From: Rene Brun (Rene.Brun@cern.ch)
Date: Fri May 18 2001 - 17:44:12 MEST


Hi Miro,

Interesting case. The I/O is correct, but the problem is with TTree::Draw
in case this function is called in the same unit filling the Tree.
If you close the file, open it again, read the tree and tree.Draw
results will be correct.
In version 3.01/02 the results are correct with your test because this new
version use the new branch style by default.
We will fix the problem for the old style branches. Thanks for reporting this.

Rene Brun

iroslav Helbich wrote:
> 
>  Hi all,
> 
>   I have one problem, that I cannot solve. It regards writing an object
> with and array of integers to the root tree. Let's say one has nclusters
> in event and wants to save a variable cluster_size for each cluster. This
> may vary from event to event. It is a very useful feature and definitely
> doable since h2root converts hbook indexed blocks in desired way. I tried
> to follow ROOT user's guide and failed. If I display values stored in
> int* arr it gives me plot with all values being 1. Why? Also Data members
> have names fX,fY on the tree; how can I change these names?
> 
>  I couldn't get a support in our Collaborations since after experiencing
> problems, people just quit using I/O. Maybe it is a problem of poor
> documentation on the web.
> 
> The files are attached. I compile it this way
> 
> rootcint TestClassDict.cxx -c TestClass.h
> g++ -O -Wall -fPIC -I$ROOTSYS/include -c TestClass.cxx
> g++ -O -Wall -fPIC -I$ROOTSYS/include -c TestClassDict.cxx
> g++ -shared -O TestClass.o TestClassDict.o -o libTestClass.so
> 
> I'm using root Version   3.00/06 on Suse Linux
> 
>                                         Miro
> 
>   --------------------------------------------------------------------------------
> 
>                        Name: TestClass.cxx
>    TestClass.cxx       Type: Plain Text (TEXT/PLAIN)
>                    Encoding: BASE64
> 
>                      Name: TestClass.h
>    TestClass.h       Type: Plain Text (TEXT/PLAIN)
>                  Encoding: BASE64
> 
>                  Name: runit.C
>    runit.C       Type: Plain Text (TEXT/PLAIN)
>              Encoding: BASE64



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