Returns the Median Moving Average of a given period of the data series provided for all possible periods for the data given.
[Visual Basic]
Overloads Public Shared Function MedianMovingAverage( _
ByVal seriesName As String, _
ByVal highSeries As Series, _
ByVal highSeriesElementValue As ElementValue, _
ByVal lowSeries As Series, _
ByVal lowSeriesElementValue As ElementValue, _
ByVal lengthOfMA As Integer _
) As Series
[C#]
public static Series MedianMovingAverage(
string seriesName,
Series highSeries,
ElementValue highSeriesElementValue,
Series lowSeries,
ElementValue lowSeriesElementValue,
int lengthOfMA
);
A series where the first term is the value of the Median Moving Average for the most recent period, the second term is the value of the Median Moving Average for the previous period and so on.
Exception | Description |
---|---|
ArgumentException | Thrown if the series historicalHigh and historicalLow are of different lengths or if one of these arrays is empty. |
For example, if we are considering a trading asset and the periods considered are days
then by passing an series containing the closing daily prices of a given asset, and by choosing to
use the 5-day median moving average (i.e. passing a length of the MA of 5
), then we will
evaluate the Median Moving Average(GMA) for all days for which the closing price on that day and
the four previous days is known.
Remark: This indicator is particularly appropriate for traded assets where the opening and closing prices are unreliable. Such an instance are FTSE stocks which in the first hour of trading experience relatively low volumes and the closing prices are settled through an auction process. Hence for the FTSE market the quoted market price at the beginning and end of the market may not be indicative of where a given stock is trading within a given period. In such markets it may be more appropriate to use the Median Moving Average which will smooth out the effect of uncharacteristic shifts at the ends of the trading day.
FinancialEngine Class | FinancialEngine Members | Overload List
2002 - 2005 Webavail Productions Inc. & Corporate Web Solutions Ltd.. All Rights Reserved.