JS-Chaos
JS-Chaos is a trend-following Expert Advisor based on the Bill Williams Chaos theory framework, utilizing the Alligator indicator, Fractals, and Awesome Oscillator to identify trend direction and entry points. The EA enters long positions when the price is above the Alligator's teeth and the Awesome Oscillator confirms upward momentum, while short entries are triggered by the inverse conditions. Exits are managed via fractal-based stop losses and the Alligator's line crossovers as trend reversal signals.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
| Symbol | P&L | Annual | Max DD | Trades | Win rate | Sharpe | Recovery | Losing streak | Per trade | Status |
|---|---|---|---|---|---|---|---|---|---|---|
| EURUSD | +3.85% | +3.33% | 3.97% | 26 | 56.00% | 0.72 | 0.97 | 2 | +$15.69 | Reliable |
| GBPUSD | -4.79% | -4.17% | 8.70% | 42 | 43.90% | -0.67 | -0.55 | 5 | −$12.39 | Reliable |
| USDJPY | -1.09% | -0.94% | 5.20% | 65 | 32.80% | -0.23 | -0.21 | 6 | −$1.70 | Reliable |
| XAUUSD | +52.77% | +41.93% | 95.25% | 37 | 40.50% | 1.06 | 0.55 | 6 | +$142.63 | Reliable |
Profitable on 2 of 4 markets with reliable results.
Converted from MQL5 to Python and run with the same rules for every EA. Positions use MT5 lot sizes (100,000 units per FX lot, 100 oz per gold lot) with 1:100 leverage, one order at a time, and a stop-out below 10% of the starting balance. Sharpe is computed from the equity curve. Results marked as unreliable are shown for completeness only.
Against the other Trend Following EAs with a reliable result on the same market: EURUSD: better than 79% of 95 · GBPUSD: better than 17% of 95 · USDJPY: better than 45% of 95 · XAUUSD: better than 78% of 96
Month by month
| Market | Months with a gain | Best month | Worst month |
|---|---|---|---|
| EURUSD | 54% | +3.59% 2026-03 | -1.92% 2026-04 |
| GBPUSD | 38% | +2.81% 2026-09 | -4.39% 2026-04 |
| USDJPY | 31% | +1.63% 2026-09 | -1.51% 2026-05 |
| XAUUSD | 54% | +165.27% 2026-03 | -34.43% 2026-08 |
From the backtest equity curve, sampled about every two days; only reliable results.
Blow-up risk: No blow-up pattern found
None of the usual blow-up patterns were found in the code, and the account was not stopped out in our backtests. That is not a guarantee: any EA can lose money.
High: stopped out in our backtest, or martingale/grid sizing without a stop loss. Elevated: martingale or grid sizing with a stop loss, or several positions at once without a stop loss. What the label means and what we found →
Strategy analysis
The core strategy of this EA is based on Bill Williams' Chaos Theory, using the Alligator indicator (Jaw, Teeth, Lips smoothed moving averages) to determine market trend direction and strength. Entry conditions for long positions require price above the Alligator Lips line, a positive and rising Awesome Oscillator (AO), and an upward fractal breakout signal; short entry conditions are the inverse. Exit conditions rely on fractal-based stop losses, placing stops at the most recent fractal high or low, while Alligator line crossovers or convergence signal trend exhaustion for position closure. Position sizing uses fixed lots or a percentage of account balance, with no Martingale or grid components detected. Money management is handled through dynamically determined stop loss distances based on fractal positions, but the EA lacks explicit take-profit logic and maximum drawdown control mechanisms. The overall strategy logic is clear and well-structured, but over-reliance on indicator signals can generate frequent false signals in ranging or choppy markets.
Strengths
- Based on the well-established Chaos Theory framework with solid theoretical backing for the strategy logic
- Uses multiple indicator confluence for signal confirmation, reducing the risk of false breakouts
- Fractal-based stop loss dynamically adjusts stop levels to adapt to market volatility
- No Martingale or grid strategy employed, making risk more controllable
- Alligator indicator effectively filters noise in ranging markets
Weaknesses
- In ranging markets, the Alligator frequently converges and diverges, generating consecutive losing signals
- Lacks explicit take-profit strategy, profits may be significantly given back during trend reversals
- No maximum drawdown limit set, potentially causing severe losses in extreme market conditions
- Fractal-based stops can result in excessively large or small stop distances in low volatility environments
- Missing trading session filter and spread filter, may open positions under unfavorable conditions
Possible improvements
- Add explicit take-profit logic, such as ATR-based dynamic targets or risk-reward ratio calculations
- Implement maximum drawdown control and daily loss limits to enhance capital safety
- Add trading session filters and spread checks to avoid trading under unfavorable conditions
Risk assessment
Overall risk: Medium
- Lacks maximum drawdown control mechanism, extreme markets may cause significant losses
- No spread filter, slippage risk increases in high-spread environments
- Fractal-based stop loss may fail in low liquidity markets
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
Lots | 0.1 | Fixed trading lot size |
StopLoss | 0 | Stop loss in points, 0 to disable |
TakeProfit | 0 | Take profit in points, 0 to disable |
TrailingStop | 0 | Trailing stop in points, 0 to disable |
MagicNumber | 12345 | EA magic number for identifying orders |
Timeframe | H1 | Trading timeframe |
JawPeriod | 13 | Alligator jaw period |
TeethPeriod | 8 | Alligator teeth period |
LipsPeriod | 5 | Alligator lips period |
Similar Trend Following EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.