Datum From Series Example

procedure Form.Average;

{Average the x values for Graph series 1.}

var i,N:Integer; x,y,sum:Double;

begin

sum:=0;

With Graph Do

begin

N:=numPointsFromSeries(1);

For i:=1 to N do

begin

DatumFromSeries(1,x,y)

sum:= sum+x;

end;

sum:=sum/N;

end;{of with}

end;