Re: [ROOT] Temporary histogram names

From: Fred Gray (fegray@uiuc.edu)
Date: Tue May 02 2000 - 03:40:29 MEST


> I sometimes use temporary histograms within a function
> to simplify some calculation.  Since each histogram
> apparently has to have a unique name, I sometimes end
> up stepping on some histogram name that I had used
> elsewhere, either blowing it away or getting an error
> about different histogram types of the same name being
> used.  Is there a simple way around this problem?

I usually use

hist->SetDirectory(0);

to remove hist from the global namespace.

-- Fred



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