Re: TGraph::Min/Max

From: Rene Brun (Rene.Brun@cern.ch)
Date: Sun Feb 27 2000 - 09:35:53 MET


Anton,
If you have a TGraph *gr, you can do
  int n = gr->GetN();
  float *x = gr->GetX();
  int locmin = TMath::LocMin(n,x);
  float xmin = x[locmin];

I could add the functions TGraph::GetMinimum, etc to save these
few lines of code.

Rene Brun


On Sat, 26 Feb 2000, Anton Fokin wrote:

> Hi rooters,
> 
> I think it would be good to have GetMin/MaxX() GetMin/MaxY() in TGraph. At
> least I have a situation where I need it.
> 
> Regards,
> Anton
> 



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