Does anyone having a function to calculate EMA that they would be willing to share? Would like to input an array of values & a period & get back the EMA value. Thanks if you can help...
Printable View
Does anyone having a function to calculate EMA that they would be willing to share? Would like to input an array of values & a period & get back the EMA value. Thanks if you can help...
The Wikipedia entry on the subject is a bit of a mess, though it does give a simple [tail] recursive formula for computing the EMA. What exactly is your difficulty?
I ended up finding & using the built-in financial functions of the chart control. It allows me to get the data I need without having to actually put a chart control on my form.