Let's build the "Trend Reversals with ATR Stop" system.
Example: Mov(C, 50, S) calculates a 50-period Simple Moving Average of the Close. RSI(Periods) Example: RSI(14) The Ref Function: This looks back at previous bars. Example: Ref(C, -1) looks at yesterday’s closing price. The Cross Function: Essential for crossover strategies. metastock formulas
Writing formulas can be finicky. Keep these tips in mind to avoid errors: Let's build the "Trend Reversals with ATR Stop" system
"Breakout above a 20-day high, but only if volume was low for the previous 5 days." backtest it mercilessly
Start simple. Master Cross() and MOV() . Gradually incorporate Alert() and BarsSince() . Build your system, backtest it mercilessly, and then—and only then—trade it live.