Re: [ROOT] bug in h2->draw("cont") ?

From: Rene Brun (Rene.Brun@cern.ch)
Date: Thu May 22 2003 - 00:42:30 MEST


Hi,

Some changes have been made in the past few weeks by Olivier Couet
to solve the kind of problems you are reporting.
Take the version from CVS head and install from source.

Rene Brun

On Wed, 
21 May 2003, Mayly Sanchez wrote:

> 
> Hi,
> I have a macro for drawing non-equidistant 2d contours that used to 
> work before but fails in most recent versions of root. The latest test 
> has been done with 3.05/05.
> 
> Here are the steps I follow:
> {TH2F *ch = new 
> TH2F("ch","",nbinx,nbinxmin,nbinxmax,nbiny,nbinymin,nbinymax);
> ch->Fill(x,y,weight);
> ch->SetContour(2);
> ch->SetContourLevel(0,0.0)
> ch->SetContourLevel(1,2.0)
> 
> ch->Draw("cont2");
> }
> 
> Now what happens is: that if I do a lego2 plot before drawing the 
> contours, the levels are set at the proper heights. Once I have run 
> Draw("cont2") or any of the other cont options it recalculates the 
> levels in a weird way. It seems to put the first level at the 
> GetMinimum value and the second half way between the maximum and the 
> minimum, as if it wanted to do equidistant contours.
> 
> Did something change? Can I force it to do non-equidistant contours 
> again? I need this urgently so any workarounds are welcome, thanks,
> 
> Mayly
> 
> ps. the method with SetContourLevels(2,vector) was also tested and gave 
> the same results
> 
> 



This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:11 MET