Join waitlist
Strategies / Momentum / Stochastic Eighty Level Crossover

Stochastic Eighty Level Crossover

Calculates raw stochastic %K over 30 bars. It buys when %K crosses above 80 and sells when it crosses back below 80.

MomentumLong onlySwingGold4 hours
1.34Profit factor
2,271Net profit EUR
31.60%Win rate
1,424Trades
-554Max drawdown
1.59Avg trade

Best run of 8. Gold, 4 hours, spread 0.6, from run pf:2026-10-12-GOLD-4h.tsv:9.

Entry rules, long

  1. Raw %K is 100 times (close minus 30-bar lowest low) divided by the 30-bar high-low range.
  2. A long is opened at market on that cross when no long position is open.

Exit rules

  1. The long is sold at market when raw %K crosses under 80.

Test conditions

PeriodUp to 2026-10-12
InstrumentGold, 4 hours
Spread0.6 points
Starting capital1,000,000
CostsSpread only. Commissions and overnight financing are not included.
BarsUp to 200,000 bars, fewer where the instrument has less history
Last tested2026-10-12

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
GoldBest run4 hours1.34 1,42431.602,271 EUR-554
USD/JPYDaily1.33 60134.781,061,490 USD-190,850
Nikkei 2254 hoursn/a 1,25631.6920,452 USD-5,909
Nasdaq 100Dailyn/a 63333.498,778 EUR-3,005
DAX 40Dailyn/a 79934.297,418 EUR-2,949
DAX 404 hoursn/a 1,47332.456,736 EUR-2,294
GoldDailyn/a 63034.922,323 EUR-755
S&P 500Dailyn/a 84331.671,177 EUR-721

Charts

Results by run

Above 1.0 made money, below 1.0 lost money.

The code

ProBuilder code, as tested

// ==============================================================
// Stochastic Eighty Level Crossover
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Momentum
// Direction: Long only
// Timeframe tested: 4 hours
// ==============================================================

DEFPARAM CumulateOrders = false

ONCE myK = 50

hi = highest[30](high)
lo = lowest[30](low)

16 more lines: the entry and exit rules.

Setup

How to load it

  1. Copy the code with the copy button on the code block.
  2. In ProRealTime, open a chart of the instrument and timeframe you want to test, then open ProOrder > New trading system and choose "Create with programming".
  3. Paste the code, give the system a name and save it.
  4. Click "Backtest", set your own spread and position size, and run it before you consider trading it live.

Indicators used

Stochastic
Read this firstKnown weaknesses2 points
  • The code sets no stop loss, so a losing trade stays open until an exit signal arrives.
  • Results include the spread only. Commissions and overnight financing are not included.

Questions

About this strategy

Can I run Stochastic Eighty Level Crossover in ProOrder?

Yes. The code is ProBuilder and runs as an automated ProOrder system. Backtest it on your own account with your own spread and position size before trading it live.

Which markets was it tested on?

It was tested on 8 market and timeframe combinations. The best run was Gold, 4 hours, with a profit factor of 1.34 over 1,424 trades.

How large was the drawdown?

The best run had a maximum drawdown of 554 EUR at the tested position size, against a net result of 2,271 EUR.

Does it trade long, short or both?

It only takes long trades.

Related

Strategies like this one

Reversal Pattern With Chaikin Volatility

Uses the same indicator.

2.26 PF · 6,872 trades

CCI Breakout

Best run on the same market, Gold.

1.08 PF · 6,065 trades

PPO Histogram Trend Persistence

Also a momentum strategy.

1.34 PF · 358 trades

Get the full rules, the complete code and the ProRealAlgos portfolio as a member.

The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.

Past backtest results do not guarantee future results. This is not financial advice. Curated and maintained by ProRealAlgos. ProRealTime™ is a trademark of ProRealTime SAS. prorealalgos.comStatsDocs