dotnetCHARTING Send comments on this topic.
DMISignal(SeriesCollection,Int32,Int32) Method
See Also 
dotnetCHARTING Namespace > FinancialEngine Class > DMISignal Method : DMISignal(SeriesCollection,Int32,Int32) Method


sc
A collection of financial series objects. For example, to evaluate this indicator for two series you will need to pass a series collection containing this two series.Please note that in order to calculate this indicator the elements of the financial series must contain High, Low and Close values.
method
Determines the methods used for the evaluation of the moving average in accordance with the following key:
  1. 1 = Simple moving average
  2. 2 = Geometric moving average
  3. 3 = Linearly weighted moving average
  4. 4 = Exponentially Weighted Moving average within smoothing fact set to be 0.5.

For further details concerning the definition of these moving averages please see the accompanying PDF documentation or the API documentation for SimpleMovingAverage.

lengthOfMA
The number of periods over which the moving average is considered.
Evaluates what is know as the Directional Motion Indicator (MDI) Trading Signal.

Syntax

Visual Basic (Declaration) 
Public Overloads Shared Function DMISignal( _
   ByVal sc As SeriesCollection, _
   ByVal method As Integer, _
   ByVal lengthOfMA As Integer _
) As SeriesCollection
Visual Basic (Usage)Copy Code
Dim sc As SeriesCollection
Dim method As Integer
Dim lengthOfMA As Integer
Dim value As SeriesCollection
 
value = FinancialEngine.DMISignal(sc, method, lengthOfMA)
C# 
public static SeriesCollection DMISignal( 
   SeriesCollection sc,
   int method,
   int lengthOfMA
)

Parameters

sc
A collection of financial series objects. For example, to evaluate this indicator for two series you will need to pass a series collection containing this two series.Please note that in order to calculate this indicator the elements of the financial series must contain High, Low and Close values.
method
Determines the methods used for the evaluation of the moving average in accordance with the following key:
  1. 1 = Simple moving average
  2. 2 = Geometric moving average
  3. 3 = Linearly weighted moving average
  4. 4 = Exponentially Weighted Moving average within smoothing fact set to be 0.5.

For further details concerning the definition of these moving averages please see the accompanying PDF documentation or the API documentation for SimpleMovingAverage.

lengthOfMA
The number of periods over which the moving average is considered.

Return Value

Returns -1, 0, or 1 respectively according to whether a sell, no action or buy signal is generated.

Remarks

This signal determines whether a given asset or index should be sold, brought or no action should be taken for a given asset under consideration. This trading signal forms the basis of the DMI Trading System which was developed by Welles Wilder.

At its simplest level to DMI system states that when the PDI crosses above the MDI a buy signal is generated and when the MDI crosses above the PMI then a sell signal is generated. This however may generate an excessive number of signals and hence we offer the possibility to smooth out these indicators according to a moving average which will help to reduce to sensitivity of the trading system.

Advantages to this Approach

This trading approach will reveal a trend before it is detected by most market participants. Once the trend becomes more widely recognized other market participants will tend to buy the tend and hence re-enforcing the trend dynamics. Hence the DMI system offers a good risk/reward trend following system.

See Also

© 2021 All Rights Reserved.