ADXCustom (Function)
The ADXCustom series function returns the average of the directional movement index (DMI) for a security.
Syntax
ADXCustom(PriceH,PriceL,PriceC,Length)
Returns (Double)
A positive numeric value for the current bar.
Parameters
Name | Type | Description |
PriceH | Numeric | Specifies which bar value (price, function, or formula) to use for the directional movement high price. |
PriceL | Numeric | Specifies which bar value (price, function, or formula) to use for the directional movement low price. |
PriceC | Numeric | Specifies which bar value (price, function, or formula) to use for the directional movement close price. |
Length | Numeric | Sets the number of bars to consider for the directional movement index plus calculation. |
Remarks
ADXCustom attempts to measure the trending quality of a security independent of direction. The greater the ADXCustom value, the stronger a security is trending.
ADXCustom provides added flexibility over the normal ADX function by allowing you to specify what High, Low, and Close values to use. This is generally used to reference multi-data elements other than Data1.
The DirMovement function calculates the DMI and ADX values.
The value for the Length input parameter should always be a whole number.
Example
Assigns the ADXCustom value of the second data element in a chart (Data2) to Value1, where the ADX length is 14 bars, then plots Value1:
Value1 = ADXCustom(High of Data2, Low of Data2, Close of Data2,14);
Plot1(Value1, "ADXCus");
Reference
Wilder, J. Welles, Jr. New Concepts in Technical Trading Systems (Greensboro, NC: Trend Research, 1978).
See Also