Easy Language question on MA trend extrapolation

greg108

Newbie
Messages
5
Likes
0
The task is simple I want to extrapolate Moving Average trend in a strait line into the future, so I have to connect 2 functions, where second extrapolating function references differential between 2 last data points of the moving average and builds trend into the future based on such slope.

In excel it is strait forward because of easy cell references, but in EL it must be a certain magic word or something to reference just 2 last points of previous function and build up a new function based on that input. Need some help with example or please direct me to the particular post on TS forum as I can't find anything related. Need a link or page or just post code sample here.

Thanks,
Greg.
 
Top