Page 1 of 1

custom series function

Posted: Tue Dec 28, 2004 2:14 am
by 9340187
Has anyone coded a function to take the derivative
of a series in Teechart VII?. We have a time series and need to
take the derivative.

Jennifer

Posted: Tue Dec 28, 2004 10:16 am
by Marjan
Hi.

You want to calculate the time derivative of source series ? If yes then you can relatively easy derive new function type from existing TTeeFunction and calculate derivative with one of the available difference formulaes, for example:

Code: Select all

dot_x[n] = (x[n+1]-x[n])/(t[n+1]-t[n])
Of course, you can use higher level difference formula or more complex functions to evaluate derivative at specific point, but the basic idea is the same. To learn more about deriving new function type check TeeChart tutorials and the article about functions I posted on this site.

Posted: Mon Jan 03, 2005 1:51 am
by 9340187
Thanks-

We ened up generating another series and loaded it from the
poarent series and that worked fine. Not as elegant, but works. This
is the week to tackle functions.

Jennifer