[ROOT] bug in TGraph::RemovePoint(Int_t ipoint) ?

From: David d'Enterria (denterria@nevis.columbia.edu)
Date: Mon Jan 06 2003 - 00:43:54 MET


Hi ROOT team,

I seem not to be able to remove the last point of a TGraph(Errors) in a 
systematic way using RemovePoint(i):

The attached macro shows the case ...

root [19] .x /home/enterria/removeLastPoints.C(1)
x[0]=5, y[0]=5, ex[0]=0.01, ey[0]=0
x[1]=7, y[1]=7, ex[1]=0.02, ey[1]=0
x[2]=9, y[2]=10, ex[2]=0.02, ey[2]=0
x[3]=13, y[3]=14, ex[3]=0.01, ey[3]=0
x[4]=15, y[4]=16, ex[4]=0.01, ey[4]=0
 <I> Removing point 4 of the graph   // <--- here it works as expected ...

x[0]=5, y[0]=5, ex[0]=0.01, ey[0]=0
x[1]=7, y[1]=7, ex[1]=0.02, ey[1]=0
x[2]=9, y[2]=10, ex[2]=0.02, ey[2]=0
x[3]=13, y[3]=14, ex[3]=0.01, ey[3]=0

root [20] .x /home/enterria/removeLastPoints.C(2)
x[0]=5, y[0]=5, ex[0]=0.01, ey[0]=0
x[1]=7, y[1]=7, ex[1]=0.02, ey[1]=0
x[2]=9, y[2]=10, ex[2]=0.02, ey[2]=0
x[3]=13, y[3]=14, ex[3]=0.01, ey[3]=0
x[4]=15, y[4]=16, ex[4]=0.01, ey[4]=0
 <I> Removing point 3 of the graph    // <-- what about point 4 ?

x[0]=5, y[0]=5, ex[0]=0.01, ey[0]=0
x[1]=7, y[1]=7, ex[1]=0.02, ey[1]=0
x[2]=9, y[2]=10, ex[2]=0.02, ey[2]=0
x[3]=15, y[3]=16, ex[3]=0.01, ey[3]=0

Is this the expected behaviour of the function or I'm missing something 
here ?

Thanks in advance,

--
 David D'ENTERRIA                     PostDoctoral Research Scientist
 Nevis Labs                  http://www.nevis.columbia.edu/~denterria
 Columbia University, NY          mailto:denterria@nevis.columbia.edu
 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 PHENIX Group (Bldg 510C)                        tel: +1 631 344 7053
 Brookhaven National Lab, Upton, NY 11973        fax: +1 631 344 3253
 http://www.phenix.bnl.gov/~enterria          mailto:denterri@bnl.gov
 ---------------------------------------------------------------------






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