Re: [ROOT] TMultipleGraph ?

From: Rene Brun (Rene.Brun@cern.ch)
Date: Thu Oct 12 2000 - 18:09:24 MEST


Hi Peter,
yes, this can be implemented a la TMultiGraph (say TMultiHist).
This will also be the way to support additional options, such as
stacked lego plots.

Rene Brun


Peter Steinberg wrote:
> 
> Will there be (or is there?!) an version of this for histograms?
> 
> although it's a simple exercise to roll your own, it would be nice to have
> an "official root" way to manage groups of drawable objects.  that is,
> i like to have just one object to draw when i have N histograms and graphs
> that i always overlay.
> 
> - Peter
> 
> On Thu, 12 Oct 2000, Rene Brun wrote:
> 
> > Hi Anton,
> > See class TMultiGraph at URL:
> >
> > http://root.cern.ch/root/htmldoc/TMultiGraph.html
> >
> > Code also available in CVS
> >
> > Rene Brun
> >
> >
> > KOSU_FOKIN@garbo.lucas.lu.se wrote:
> > >
> > > Hi Rene,
> > >
> > > I am frequently drawing one, two or more graphs
> > > on the same plot using TH2F as an underlying histogram.
> > > To fit all the graphs (with some margines) into
> > > the histogram I have to use the folowing procedure
> > >
> > > - find min/max of all graphs
> > > - book or rebin the histogram to fit min max
> > > - draw hist
> > > - draw graphs
> > >
> > > I also need to apply this procedure every time one
> > > of the graphs changes to fit it into the histogram.
> > >
> > > Could you make this procedure a kind of automatic?
> > > Why should a user deal with booking a histogram,
> > > finding/setting min and max, number of bins, etc.
> > >
> > > A kind of normal way to do it is use somethig like
> > >
> > > TMultipleGraph *MultipleGraph = new TMultipleGraph(Graph1);
> > >
> > > MultipleGraph->Draw();
> > >
> > > MultipleGraph->AddGraph(Graph2);
> > >
> > > etc.
> > >
> > > Or I am missing something as usual?:))
> > >
> > > Regards,
> > > Anton
> >



This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:35 MET