ExpPinBar
ExpPinBar is an Expert Advisor that identifies pin bar candlestick reversal patterns and executes trades based on them. It scans for bullish and bearish pin bars as signals of potential market reversals, entering positions in the direction of the implied reversal. The EA includes configurable pattern recognition thresholds and basic risk management via stop loss and take profit.
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 | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| GBPUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| USDJPY | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
| XAUUSD | 0.00% | 0.00% | 0.00% | 0 | — | — | — | — | — | Not convertible yet |
Why this EA never traded: no entry rule survived the conversion.
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.
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 concept of the ExpPinBar strategy is based on the classic Pin Bar candlestick reversal pattern, which is one of the most widely recognized reversal signals in price action trading. Entry conditions require identifying a pin bar that meets specific ratio criteria: the wick must be significantly longer than the body, and the wick must point in the direction of the implied reversal — a bullish pin bar has a long lower wick indicating buyer strength, while a bearish pin bar has a long upper wick indicating seller strength. Exit conditions are implemented through configurable stop loss and take profit parameters, with the stop loss typically placed beyond the extreme of the pin bar wick. Position sizing uses a fixed lot approach where the user sets the trade volume through a parameter. Money management is relatively basic, lacking dynamic position sizing or account-equity-based proportional risk control, with risk management relying entirely on the proper configuration of stop loss and take profit parameters.
Strengths
- Based on a classic price action pattern with clear and understandable strategy logic backed by solid market theory
- Pin bars are high-probability reversal signals that perform exceptionally well when combined with key support and resistance levels
- Highly configurable parameters allow users to adjust pattern recognition thresholds for different instruments and timeframes
- Includes spread filter and magic number, providing basic trade environment protection mechanisms
Weaknesses
- Lacks a trend filter mechanism, which can lead to consecutive losses from counter-trend pin bar signals during strong trending markets
- Position sizing is overly simplistic; fixed lots cannot dynamically adjust based on market volatility or account risk
- No multi-timeframe confirmation, making single-timeframe signals prone to false breakouts
- Lacks a trailing stop feature, unable to lock in floating profits after a trend reversal
Possible improvements
- Add a trend filter (such as moving average direction or ADX indicator) to only enter on pin bars against the prevailing trend direction, improving signal quality
- Implement ATR-based dynamic stop loss, take profit, and position sizing calculations to make risk management adaptive to different market volatility environments
Risk assessment
Overall risk: Medium
- Fixed lot sizing without dynamic risk control may lead to excessive risk exposure on small accounts or highly volatile instruments
- Lack of trend filtering means counter-trend pin bar signals can generate frequent false signals and consecutive losses during strong trending markets
- No check for existing positions in the same direction, potentially causing duplicate entries and over-concentrated risk exposure
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
LotSize | 0.1 | Lot size for margin calculation |
StopLoss | 500 | Stop loss in points |
TakeProfit | 1000 | Take profit per order (points) |
PinBarRatio | 2.0 | Minimum wick-to-body ratio for pin bar |
MaxSpread | 30 | Maximum allowed spread |
MagicNumber | 12345 | EA magic number for identifying orders |
Similar Candlestick Pattern EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.