PROTECTED SOURCE SCRIPT

CLEVER v15

169
BTCUSD EURUSD DXY USOIL The CLEVER v15 strategy is a highly modular and adaptive multi-setup trading system built in Pine Script v5. It’s designed for flexible use on TradingView and combines Renko and Heikin-Ashi logic, EMA cloud trends, ATR-based risk management, and a sophisticated multi-target take-profit system.
Here’s what it does in plain language 👇

🧠 1. Core Concept

CLEVER is a hybrid trading strategy that can generate buy/sell signals based on:

Heikin-Ashi Open/Close crossovers, or

Renko-based EMA crossovers

The trader chooses between “Open/Close” or “Renko” setups, defining how signals are generated.

⚙️ 2. Signal Generation

A. Open/Close Mode

A Buy signal triggers when the Heikin-Ashi Close crosses above its Open.

A Sell signal triggers when the Heikin-Ashi Close crosses below its Open.

This setup uses candle momentum and trend filtering logic.

B. Renko Mode

Uses two EMAs (default: 2-period and 10-period) applied to Renko prices.

Buy signal when EMA(2) crosses above EMA(10).

Sell signal when EMA(2) crosses below EMA(10).

Renko data smooths out noise and focuses on structure.

🧭 3. Trend Filtering

The strategy optionally filters trades using ATR and/or RSI logic:

ATR filter measures market volatility.

RSI filter checks overbought/oversold or sideways ranges.

You can combine them in several modes (e.g., “ATR or RSI”, “ATR and RSI”, “Sideways Only”).

Only trades that meet these market conditions are allowed.

🎯 4. Trade Execution Logic

The user selects a Trade Processing System (TPS) mode:

ATR-based – Full multi-level risk/reward management (main mode)

Trailing – Uses dynamic order exits with alerts

Options – Simpler entry/exit rules, used for external automation

Depending on the mode, the strategy:

Opens long/short positions when triggers occur.

Closes or reverses trades on opposite signals or exit conditions.

Can process signals only within a defined backtest date range.

📈 5. Risk Management (ATR-Based)

Uses the Average True Range (ATR) to calculate dynamic Take-Profit (TP) and Stop-Loss (SL) levels.

Default TP/SL factors:

TP1 = 2.5× ATR

TP2 = 5× ATR

TP3 = 7.5× ATR

SL = 2.5× ATR (in opposite direction)

Each level can close a percentage of the position (default: 50% / 30% / 20%).

Partial exits are handled by strategy.exit() with dynamic lines and alerts.

📊 6. Visual Features

The strategy displays:

Colored bars showing the trend (green for bullish, red for bearish).

EMA & Renko Clouds — visually shaded zones showing directional bias.

Dynamic lines for entry, SL, and each TP level.

Labels and fills showing profit/loss areas (TP area in blue, SL in red).

Performance dashboards:

Overall strategy performance (win rate, avg win/loss, profit factor, etc.).

Weekly and Monthly trade statistics tables.

🧩 7. Additional Components

Backtest Dashboard: Displays closed trades, win rate, max drawdown, and more.

Weekly & Monthly Performance Tables: Show profitability by day and month.

Alerts System: Sends alerts for all key events:

Entry (Long/Short)

Exit (Close, TP, SL)

Any Signal Trigger

Multi-timeframe EMA and ATR Clouds: Use higher-timeframe smoothing if enabled.

⚡ 8. Trade Flow Summary

Here’s how a typical trade works:

Market meets filter conditions (RSI/ATR logic passes).

Buy or Sell trigger fires (Renko EMA or HA crossover).快照

Entry is executed (strategy.entry()).

ATR determines three TP targets and one SL level.

When TP1, TP2, or TP3 is hit:

Partial profit is taken.

Chart marks the event (label + line).

If SL is hit, trade closes fully.

Dashboards update with results.

🎨 9. Customization

Everything — from colors, transparency, TP/SL ratios, date filters, and visualization — is customizable through inputs.

🧾 10. Summary

In short, the CLEVER v15 XAUUSD XAUUSD strategy is:

A full-featured multi-mode trading system combining Heikin-Ashi, Renko, EMA, and ATR logic with multi-target exits, trend filtering, and visual performance dashboards for professional backtesting and trade automation.

免責聲明

這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。