API MA Method constants

From NakedMarkets
Revision as of 03:56, 5 January 2023 by NMWikiWeb (talk | contribs) (Created page with "=== Summary === The MA Method constants are used in Moving Average functions to set the type of the Moving Averag <br> === Definition === {| class=wikitable cellpadding="10"...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Summary

The MA Method constants are used in Moving Average functions to set the type of the Moving Averag

Definition

Constant name Description
MA_Method.MODE_SMA Simple Moving Average (SMA)
MA_Method.MODE_EMA Exponential Moving Average (EMA)
MA_Method.MODE_SMMA Smoothed Moving Average (SMMA)
MA_Method.MODE_LWMA Weighted Moving Average (LWMA)

Examples

C# code snippet :
double value = GetMA(Symbol(), Period(), index, 0, period, MA_Method.MODE_SMA, Applied_Price.PRICE_WEIGHTED, MA[index + 1]);