Any function for Exponential Weighted Moving Average?

TeeChart for ActiveX, COM and ASP
Post Reply
Evan
Newbie
Newbie
Posts: 2
Joined: Tue Jul 18, 2006 12:00 am

Any function for Exponential Weighted Moving Average?

Post by Evan » Wed Aug 02, 2006 9:13 am

I found the series function has Moving Average, or Exponential Average, but not Exponential Weighted Moving Average. Any idea of how to generate?

stark
Newbie
Newbie
Posts: 10
Joined: Wed Jul 26, 2006 12:00 am
Location: Girona / Catalunya

Post by stark » Wed Aug 02, 2006 11:00 am

Hello Evan,

you can add your own function at TChart1_OnSeriesBeforeAdd(ByVal SeriesIndex As Long, MoreValues As Boolean)

here is small example:

Private Sub TChart1_OnSeriesBeforeAdd(ByVal SeriesIndex As Long, MoreValues As Boolean)
If SeriesIndex = 1 Then
TChart1.Series(SeriesIndex).YValues.TempValue _
= TChart1.Series(0).YValues.Value(TChart1.Series(SeriesIndex).Count) + 10
End If
Best regards
Alex

Steema Crew

Post Reply