Skip to content
All library documents

RSI Threshold-Crossing Signals and a Possible Indicator Error

Article FMZ forum · Author: MrSwinging

Summary

This short post presents a function intended to produce signals around oversold and overbought thresholds. It waits until enough market records are available, then checks the latest two indicator readings: a downward move through 30 returns one signal, while an upward move through 70 returns another. Otherwise it returns no signal. The author asks why the condition sometimes fails to trigger when used for closing positions.

There is a likely implementation mismatch: the function assigns an ATR calculation to a variable named RSI, then compares those values with RSI-style thresholds. ATR measures volatility and is not bounded like RSI, so these checks do not implement the stated RSI logic. The snippet also does not explain instrument, bar interval, position state, or how signals map to exits. It offers no test results or diagnosis of the reported missed triggers; the indicator call should be checked before interpreting the threshold conditions as RSI signals.

Key ideas

  • The function checks two successive indicator readings against thresholds of 30 and 70.
  • It returns separate signals when the latest reading crosses either threshold in a specified direction.
  • The code calls ATR despite describing the calculation as RSI.
  • ATR values do not have the bounded scale assumed by conventional RSI thresholds.
  • The post provides no test evidence explaining the reported missed exit signals.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.