[ROOT] Plotting an stl vector

From: Troy Straszheim (troy@ifh.de)
Date: Tue Jan 20 2004 - 16:53:06 MET


Hi roottalk-

I'm new to this, have what I hope is an easy question to answer:

I have a class that contains an stl vector of ints, and I use a TFile and a TTree to write it out to a file.  When I load up the file in an interactive session, I can see all the data, as expected, in my branches when I access them directly, e.g. branch->GetEntry(index).  However when I click the leave in the tree viewer, I get the message

Warning in <TSelectorDraw::ProcessFillObject>: Not implemented for vector<int,allocator<int> >

So I'm guessing that I need to somehow convert this vector into something that is plottable by root.  Can anyone suggest a techinque to do this?

I may have to repeat this process for a very large number of root files with stl vectors of various types...  the more generic the better.  Perhaps the idea is a file converter, from root-with-stl-nonplottables to root-with-plottables.

Any tips are gratefully accepted,

Thanks,

Troy Straszheim



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:05 MET