trueRange#

swordfish.function.trueRange()#

Return a vector of the same length as each of the input vectors.

The result for each position is the maximum of | high - low |, | high - last period close | and | last period close - low |.

Parameters:
  • high (Constant) – A numeric vector indicating the highest price of the current period.

  • low (Constant) – A numeric vector indicating the lowest price of the current period.

  • close (Constant) – A numeric vector indicating the closing price of the current period.

Returns:

A a vector of the same length as each of the input vectors.

Return type:

Constant