Prop Firm Business SimulatorThe prop firm business simulator is exactly what it sounds like. It's a plug and play tool to test out any tradingview strategy and simulate hypothetical performance on CFD Prop Firms.
Now what is a modern day CFD Prop Firm?
These companies sell simulated trading challenges for a challenge fee. If you complete the challenge you get access to simulated capital and you get a portion of the profits you make on those accounts payed out.
I've included some popular firms in the code as presets so it's easy to simulate them. Take into account that this info will likely be out of date soon as these prices and challenge conditions change.
Also, this tool will never be able to 100% simulate prop firm conditions and all their rules. All I aim to do with this tool is provide estimations.
Now why is this tool helpful?
Most traders on here want to turn their passion into their full-time career, prop firms have lately been the buzz in the trading community and market themselves as a faster way to reach that goal.
While this all sounds great on paper, it is sometimes hard to estimate how much money you will have to burn on challenge fees and set realistic monthly payout expectations for yourself and your trading. This is where this tool comes in.
I've specifically developed this for traders that want to treat prop firms as a business. And as a business you want to know your monthly costs and income depending on the trading strategy and prop firm challenge you are using.
How to use this tool
It's quite simple you remove the top part of the script and replace it with your own strategy. Make sure it's written in same version of pinescript before you do that.
//--$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$--//--------------------------------------------------------------------------------------------------------------------------$$$$$$
//--$$$$$--Strategy-- --$$$$$$--// ******************************************************************************************************************************
//--$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$--//--------------------------------------------------------------------------------------------------------------------------$$$$$$
length = input.int(20, minval=1, group="Keltner Channel Breakout")
mult = input(2.0, "Multiplier", group="Keltner Channel Breakout")
src = input(close, title="Source", group="Keltner Channel Breakout")
exp = input(true, "Use Exponential MA", display = display.data_window, group="Keltner Channel Breakout")
BandsStyle = input.string("Average True Range", options = , title="Bands Style", display = display.data_window, group="Keltner Channel Breakout")
atrlength = input(10, "ATR Length", display = display.data_window, group="Keltner Channel Breakout")
esma(source, length)=>
s = ta.sma(source, length)
e = ta.ema(source, length)
exp ? e : s
ma = esma(src, length)
rangema = BandsStyle == "True Range" ? ta.tr(true) : BandsStyle == "Average True Range" ? ta.atr(atrlength) : ta.rma(high - low, length)
upper = ma + rangema * mult
lower = ma - rangema * mult
//--Graphical Display--// *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-$$$$$$
u = plot(upper, color=#2962FF, title="Upper", force_overlay=true)
plot(ma, color=#2962FF, title="Basis", force_overlay=true)
l = plot(lower, color=#2962FF, title="Lower", force_overlay=true)
fill(u, l, color=color.rgb(33, 150, 243, 95), title="Background")
//--Risk Management--// *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-$$$$$$
riskPerTradePerc = input.float(1, title="Risk per trade (%)", group="Keltner Channel Breakout")
le = high>upper ? false : true
se = lowlower
strategy.entry('PivRevLE', strategy.long, comment = 'PivRevLE', stop = upper, qty=riskToLots)
if se and upper>lower
strategy.entry('PivRevSE', strategy.short, comment = 'PivRevSE', stop = lower, qty=riskToLots)
The tool will then use the strategy equity of your own strategy and use this to simulat prop firms. Since these CFD prop firms work with different phases and payouts the indicator will simulate the gains until target or max drawdown / daily drawdown limit gets reached. If it reaches target it will go to the next phase and keep on doing that until it fails a challenge.
If in one of the phases there is a reward for completing, like a payout, refund, extra it will add this to the gains.
If you fail the challenge by reaching max drawdown or daily drawdown limit it will substract the challenge fee from the gains.
These gains are then visualised in the calendar so you can get an idea of yearly / monthly gains of the backtest. Remember, it is just a backtest so no guarantees of future income.
The bottom pane (non-overlay) is visualising the performance of the backtest during the phases. This way u can check if it is realistic. For instance if it only takes 1 bar on chart to reach target you are probably risking more than the firm wants you to risk. Also, it becomes much less clear if daily drawdown got hit in those high risk strategies, the results will be less accurate.
The daily drawdown limit get's reset every time there is a new dayofweek on chart.
If you set your prop firm preset setting to "'custom" the settings below that are applied as your prop firm settings. Otherwise it will use one of the template by default it's FTMO 100K.
The strategy I'm using as an example in this script is a simple Keltner Channel breakout strategy. I'm using a 0.05% commission per trade as that is what I found most common on crypto exchanges and it's close to the commissions+spread you get on a cfd prop firm. I'm targeting a 1% risk per trade in the backtest to try and stay within prop firm boundaries of max 1% risk per trade.
Lastly, the original yearly and monthly performance table was developed by Quantnomad and I've build ontop of that code. Here's a link to the original publication:
That's everything for now, hope this indicator helps people visualise the potential of prop firms better or to understand that they are not a good fit for their current financial situation.
Educational
PRO Strategy 3TP (v2.1)**PRO Strategy 3TP (v2.1) - TradingView Strategy Guide**
**ENG | **
---
### **Strategy Overview**
The **PRO Strategy 3TP** combines multi-timeframe analysis, trend filters, and dynamic risk management to capture trends with precision. It uses EMA/HMA/SMA crossovers, CCI for overbought/oversold conditions, ADX for trend strength, and ATR-based stops/take-profits. The strategy’s uniqueness lies in its **three-tier profit-taking system**, adaptive multi-timeframe logic, and automatic stop-loss movement to breakeven after TP1.
---
### **Key Features**
1. **Multi-Timeframe Analysis**: Uses higher timeframe (e.g., 1H, 4H) indicators to filter entries on your chart’s timeframe.
2. **Trend Filters**: Combines EMA, HMA, and SMA to confirm trend direction.
3. **CCI + ADX Filters**: Avoids false signals by requiring momentum (CCI) and trend strength (ADX > threshold).
4. **ATR Volatility Adjustments**: Stop-loss (SL) and take-profits (TP1/TP2/TP3) adapt to market volatility.
5. **Breakeven Stop**: SL moves to entry price after TP1 is hit, locking in profits.
---
### **Setup & Configuration**
1. **Input Parameters**:
- **Trading Mode**: Choose LONG, SHORT, or BOTH.
- **Indicator Timeframe**: Select a higher timeframe (e.g., "60" for 1H).
- **EMA/HMA/SMA**: Toggle on/off and set lengths (default: 100, 50, 200).
- **CCI**: Set length (default: 4), overbought (+100), oversold (-100).
- **ADX**: Set length (default: 14) and threshold (default: 26).
- **ATR**: Period (default: 19), SL/TP multipliers (default: SL=5x, TP1=1x, TP2=1.3x, TP3=1.7x).
2. **Position Sizing**:
- **Always specify size in contracts**, not percentages. Calculate contracts based on your risk per trade (e.g., 1-2% of capital).
3. **Multi-Timeframe Logic**:
- Example: If your chart is 15M, set the indicator timeframe to 1H. Entries trigger when the 15M price aligns with the 1H trend.
---
### **How It Works**
- **Entry Conditions**:
- **Long**: Price > EMA/HMA/SMA + CCI < -100 (oversold) + ADX > 26 (strong trend).
- **Short**: Price < EMA/HMA/SMA + CCI > +100 (overbought) + ADX > 26.
- **Exits**:
- **SL**: 5x ATR from entry.
- **TP1**: 1x ATR profit. After TP1 hits, SL moves to breakeven.
- **TP2/TP3**: 1.3x and 1.7x ATR profit.
---
### **Example Configurations**
1. **Scalping (1-15M Chart)**:
- EMA=50, HMA=20, SMA=OFF, CCI=3, ATR=14, SL=3x, TP1=0.8x.
- Indicator TF: 5M.
2. **Swing Trading (1H-4H Chart)**:
- EMA=100, HMA=50, SMA=200, ADX=20, SL=5x, TP1=1x.
- Indicator TF: 1D.
3. **Trend Following (Daily Chart)**:
- SMA=200, ADX=25, CCI=OFF, SL=6x, TP3=2x.
---
### **ADX Explanation**
The ADX (Average Directional Index) measures trend strength. Values above 25 indicate a strong trend. The strategy uses ADX to avoid trading in sideways markets.
---
### **Risk Management**
- **Past results do NOT guarantee future performance**.
- **No universal settings**: Optimize for each asset (BTC vs. alts behave differently).
- Test settings in a demo account before live trading.
- Never risk more than 1-5% per trade.
---
### **FAQ**
**Q: Why specify position size in contracts?**
A: Contracts let you precisely control risk. For example, if your SL is 50 points and you risk $100, size = 100 / (SL distance * contract value).
**Q: How does the breakeven stop work?**
A: After TP1 (33% position closed), the SL moves to entry price, eliminating risk for the remaining position.
**Q: Can I use this on stocks/forex?**
A: Yes, but re-optimize ATR/SL/TP settings for each market’s volatility.
---
**ПРО Стратегия 3TP (v2.1) - Руководство для TradingView**
---
### **Описание стратегии**
**PRO Strategy 3TP** сочетает мультитаймфрейм-анализ, фильтры тренда и динамическое управление рисками. Уникальность: **три уровня тейк-профита**, адаптивные настройки под разные таймфреймы, автоматический перевод стопа в безубыток после TP1.
---
### **Особенности**
1. **Мультитаймфрейм**: Индикаторы строятся на старшем ТФ (например, 1H) для фильтрации сигналов.
2. **Тренд**: Комбинация EMA, HMA, SMA.
3. **CCI + ADX**: CCI определяет перекупленность/перепроданность, ADX — силу тренда.
4. **ATR**: Стопы и тейки адаптируются к волатильности.
5. **Стоп в безубыток**: После TP1 стоп двигается к цене входа.
---
### **Настройка**
1. **Параметры**:
- **Режим**: LONG, SHORT или LONG/SHORT.
- **Таймфрейм индикаторов**: Выберите старший ТФ (например, 1H).
- **EMA/HMA/SMA**: Длины (по умолчанию: 100, 50, 200).
- **CCI**: Уровни перекупленности (+100)/перепроданности (-100).
- **ADX**: Порог силы тренда (26).
- **ATR**: Период (19), множители SL/TP.
2. **Объем позиции**:
- Указывайте в **контрактах**, а не в процентах. Рассчитывайте на основе риска на сделку.
3. **Мультитаймфрейм**:
- Пример: На 15-минутном графике используйте индикаторы с 1H.
---
### **Логика работы**
- **Вход**:
- **Лонг**: Цена выше EMA/HMA/SMA + CCI < -100 + ADX > 26.
- **Шорт**: Цена ниже EMA/HMA/SMA + CCI > +100 + ADX > 26.
- **Выход**:
- **SL**: 5x ATR от цены входа.
- **TP1**: 1x ATR. После TP1 стоп двигается в безубыток.
- **TP2/TP3**: 1.3x и 1.7x ATR.
---
### **Примеры настроек**
1. **Скальпинг (1-15M)**:
- EMA=50, HMA=20, CCI=3, SL=3x, TP1=0.8x.
2. **Свинг (1H-4H)**:
- SMA=200, ADX=20, SL=5x.
3. **Тренд (Daily)**:
- ADX=25, SL=6x, TP3=2x.
---
### **Как работает ADX**
ADX измеряет силу тренда. Значения выше 25 сигнализируют о сильном тренде. Стратегия избегает входов при ADX < 26.
---
### **Риски**
- **Исторические результаты не гарантируют будущие**.
- **Нет универсальных настроек**: Оптимизируйте под каждый актив (BTC vs. альты).
- Тестируйте на демо-счете.
- Рискуйте не более 1-5% на сделку.
---
### **FAQ**
**В: Почему объем в контрактах?**
О: Чтобы точно контролировать риск. Пример: если стоп = 50 пунктов, а риск = $100, объем = 100 / (стоп * стоимость контракта).
**В: Как работает стоп в безубыток?**
О: После закрытия 33% позиции (TP1), стоп переносится на цену входа, защищая оставшуюся позицию.
**В: Подходит для акций/форекс?**
О: Да, но перенастройте ATR/SL/TP под волатильность рынка.
---
**⚠️ Warning / Предупреждение**: Trading involves high risk. Always backtest and optimize strategies. Use stop-losses. / Торговля связана с риском. Всегда тестируйте стратегии. Используйте стоп-лоссы.
vusalfx v3 Nzd/Usd 1m(RR 1:3)Indicator Description (for NZD/USD 1-Minute Chart)
This indicator is designed for scalping on the NZD/USD currency pair using a 1-minute timeframe. It combines exponential moving averages and the Relative Strength Index (RSI) to generate potential trade signals with a defined risk-to-reward ratio.
Risk/Reward Ratio: 1:3 (Risking 1% to gain 3%)
Stop Loss: 1%
Take Profit: 3%
EMA 9 (Fast EMA): Displayed in orange
EMA 21 (Slow EMA): Displayed in blue
RSI: 14-period RSI for momentum confirmation
The strategy looks for trend continuation and momentum setups based on EMA crossovers and RSI confirmation, with strict risk management.
Cyclical CALL/PUT StrategyThis script identifies optimal CALL (long) and PUT (short) entries using a cyclical price wave modeled from a sine function and confirmed with trend direction via a 200 EMA.
Strategy Highlights:
Cycle-Based Signal: Detects market rhythm with a smoothed sinusoidal wave.
Trend Confirmation: Filters entries using a customizable EMA (default: 200).
Auto-Scaling: Wave height adjusts dynamically to price action volatility.
Risk Parameters:
Take Profit: Default 5% (customizable)
Stop Loss: Default 2% (customizable)
Signal Triggers:
CALL Entry: Price crosses above the scaled wave and in an uptrend
PUT Entry: Price crosses below the scaled wave and in a downtrend
Inputs:
Cycle Length
Smoothing
Wave Height
EMA Trend Length
Take Profit %
Stop Loss %
Visuals:
Gray line = Scaled Cycle Wave
Orange line = 200 EMA Trend Filter
Best For: Traders looking to make 1–2 high-probability trades per week on SPY or other highly liquid assets.
Timeframes: Works well on 2-min, 15-min, and daily charts.
Ticker Pulse Meter + Fear EKG Strategy V4 (No Repaints)VERSION: This version is designed to improve Tradingview loading speed and it removes the long term LRC (Linear Regression Channel) thinking some folks may not want that component. So this is pretty much just the core strategy plus a couple light weight visual references (200 day MA, 100 Day Bollinger Bands).
The Ticker Pulse + Fear EKG Strategy is a long-term, dip-buying investment approach designed to balance market momentum with emotional sentiment. It combines two core components: Ticker Pulse, which tracks momentum through dual-range metrics to guide precise entries and exits, and Fear EKG, spikes in market fear to identify potential reversal points. This strategy is optimized for the daily timeframe but can also perform well on weekly or monthly charts, making it ideal for dollar-cost averaging or trend riding with confidence. Visual elements like green and orange dots, heatmap backgrounds, and SMA/Bollinger Bands offer clear signals and additional context, while the strategy’s out-of-the-box settings require little to no adjustment.
Green dots are considered high-confidence and do not repaint, while orange dots (Fear EKG entries) coincide with a red “fear” background identify added opportunities to accumulate shares during peak fear and market sell-offs.
Recent update include the separating signal types (Green Dots and Orange Dots) and offering back testing options. You can opt to include Green Dots in back testing, orange dots in back testing, or both. You can also turn off sell signals if you are truly a long term DCA style investor. This would be a buy and hold approach.
Scalping Strategy Final (Secured)Get rich very quickly!
Only signals in the direction of the market trend are displayed, enter the position when the signal is issued and stay in the position until the exit signal is issued, usually you can easily reach goal 2. Be profitable.
4 EMAs with Entry and Exit Strategy🔍 Purpose of the Script:
This strategy is designed to identify bullish trends using a combination of Exponential Moving Averages (EMAs) and the Relative Strength Index (RSI), and execute long entries and exits accordingly.
📈 Key Technical Indicators Used:
EMAs (Exponential Moving Averages):
ema9, ema21, ema63, and ema200 are calculated to determine short-, mid-, and long-term trends.
An unused ema126 is mentioned but commented out.
RSI (Relative Strength Index):
A 14-period RSI is calculated and used to avoid entries when the stock is overbought.
🟢 Entry Logic (Long):
The strategy enters a long position when:
A bullish trend is confirmed by EMA alignment:
ema9 > ema21 > ema63 > ema200
The closing price is above ema9
RSI is ≤ 60, to avoid entering overbought conditions
🔴 Exit Logic (Long Exit):
The strategy exits a long position when:
ema21 crosses below ema63 (bearish signal)
There are commented-out conditions like:
RSI > 80 (overbought)
Close > 1.4 × ema126 (price extended far above average)
🎨 Visualization:
EMAs are plotted in different colors for trend visibility.
Background color turns:
Light green in bullish trend
Light red in bearish trend
⚙️ Strategy Configuration:
Capital: ₹10,00,000
Position size: 10% of equity
Commission: 0.75% per trade (roundtrip)
Overlay: true (indicators and trades plotted on price chart)
✅ Highlights:
Clear trend detection with layered EMA logic
Avoids overbought entries using RSI ≤ 60
Customizable and extendable (e.g., you can uncomment EMA126 and add price-overextension logic)
Ticker Pulse Meter Long Strategy (On Chart)The Ticker Pulse Meter Long Strategy is a straightforward, no-repaint indicator designed for long-term investors and swing traders on daily, weekly, and monthly charts. Whether you’re dollar-cost averaging (DCA) into your favorite stock or buying dips for swing trades, this tool helps you identify high-probability entry points while keeping you disciplined through market volatility. It’s perfect for value investors who want to capitalize on undervaluation without overcomplicating their approach.
How It Works
Pulse Meter Core: Measures price position relative to short (50-period) and long (200-period) historical ranges, signaling buys when the price dips into undervalued zones—ideal for catching market corrections.
Linear Regression Channel: Visualizes the long-term trend, highlighting key buy zones near the lower channel—perfect for DCA or swing entries.
High Timeframe Focus: Built for D, W, and M charts, with infrequent, high-conviction signals (1–2 trades/month). No day trading noise—just long-term value.
No-Repaint Signals: Green dots mark entries, red dots mark exits. What you see is what you get—reliable signals for confident investing.
Simple Execution: No settings to tweak. Add it to your chart, follow the signals, and hold through the storms.
Who Is This For?
Value Investors: Use it to DCA into your chosen stock, buying more on dips to lower your average cost.
Swing Traders: Capture multi-month swings on the weekly chart, holding positions for weeks to months.
Long-Term Believers: If you’re in for the long haul on a stock or asset with strong fundamentals, this indicator helps you buy smart and stay steady.
How to Use
Add to your chart (D, W, or M timeframe).
Buy on green dots (dip signals)—perfect for DCA or swing entries.
Hold through volatility (like major bear markets).
Exit on red dots (profit targets) for swings, or ignore exits for long-term holds.
Use the Linear Regression Channel to confirm buy zones near the lower band.
Important Notes
This is not a day-trading tool—built for patient, long-term strategies.
Drawdowns happen. Stay disciplined.
Back test results are historical; markets can change. Always manage risk.
Why Choose This Indicator?
Unlike overcomplicated suites with 50 settings, the Ticker Pulse Meter keeps it simple: one indicator, one goal—buy value, win long-term. It’s your edge for navigating market volatility with confidence.
This is not financial advice, I am not a financial advisor, this is for education purposes only.
If you like, please comment, boost and subscribe!
FeraTrading Take Profit ModelUnlike most trading strategies, this model does not rely on traditional entry logic . This strategy embodies the principle that time in the market is often more beneficial than trying to time the market itself.
The method operates by executing trades almost instantly when not currently positioned, but it introduces an after-bar waiting period before entering a new trade. This straightforward rule is complemented by a sophisticated framework for position sizing and exit timing.
By utilizing various volatility features, it adeptly adjusts both the size of the position and the timing of exits. The execution is clear and straightforward: buy when the price reaches the purple line, and sell once it hits the yellow line. These lines are manipulated by price action, range, and volatility. This simplicity in entry and exit, combined with advanced logic behind the scenes, creates a robust long term trading strategy.
The strategy strictly trades on the 1 day timeframe on the S&P 500 and automatically sets stop-loss (SL) and take-profit (TP) levels, helping to enforce disciplined risk management. Position sizing is straightforward and adjusts based on the user’s defined capital input, making it flexible for different account sizes.
Alerts can be created via the "Alerts" button to stay notified of key trade signals.
FeraTrading Gold Compression Breakout v1This model leverages our innovative FeraTrading Compression Indicator specifically for Gold, utilizing volatility to accurately determine both stop loss and take profit zones. It identifies potential breakouts within consolidated zones or at key support and resistance levels. It incorporates volatility filtering combined with candle analysis to enhance trading decisions. This approach aims to identify significant price movements while minimizing the influence of market noise.
The strategy strictly trades on the 1minute timeframe and automatically sets stop-loss (SL) and take-profit (TP) levels, helping to enforce disciplined risk management. Position sizing is straightforward and adjusts based on the user’s defined capital input, making it flexible for different account sizes.
Alerts can be created via the "Alerts" button to stay notified of key trade signals.
FeraTrading NQ Breakout ModelThis model integrates the FeraTrading Breakout Indicator specifically for Nasdaq, designed to capture the final breakout move with precision. By combining volatility filtering with market structure analysis and dynamic buy/sell zones, it enhances breakout detection while reducing noise.
The strategy strictly trades on the 15 minute timeframe and automatically sets stop-loss (SL) and take-profit (TP) levels, helping to enforce disciplined risk management. Position sizing is straightforward and adjusts based on the user’s defined capital input, making it flexible for different account sizes.
Alerts can be created via the "Alerts" button to stay notified of key trade signals.
Ticker Pulse Meter + Fear EKG StrategyVERSION #2
Ticker Pulse + Fear EKG Strategy
Discover a smarter way to invest with the Ticker Pulse + Fear EKG Strategy, crafted for long-term investors seeking to buy dips and lock in profits over time. Fear EKG, a unique VIX-powered oscillator, pinpoints market fear to catch reversals at their sweetest spots, while Ticker Pulse’s dual-range metrics ensure you enter with momentum and exit with precision. Optimized for the daily timeframe—yet thriving on weekly and monthly charts—this strategy empowers you to dollar-cost average or ride trends with confidence, using partial exits to secure gains without guesswork.
Works out of the box, really no need for adjustment of settings.
However, here are a couple tidbits of information on how to adjust some of the settings.
Mute Fear EKG related buy entries:
In the settings tab, if you set the Upper Signal Threshold, Mid Signal Threshold, and the Lower Signal Threshold all to 100 this will serve to mute 100% of all Fear EKG spike related buy signals.
Mute Ticker Pulse Meter related buy entries
If you set the Above Long/Above Short Level and the Below Long/Below Short Level to zero this will serve to mute all buy signals related to the ticker pulse meter.
You may also want to play with the FEAR EKG SETTINGS. For instance, if you take it down to 5 and 2 respectively and muted the Ticker Pulse Meter by zeroing them out. What you are left with are much better bottom detection. Fewer trades to stretch the money in the event of a extended bear market.
Likewise, you can mute the Fear EKG by increasing all to 100, opting to only look at the dip buys related to the Ticker Pulse Meter. This too will serve to decrease the number of entries.
Related to the added context of the long term Linear Regression Channel, if you are looking for a powerful set up, consider only entering trades when a green dot prints below the red POC, point of control.
If you study the price action, between the 200 period moving average (white line), the 100 period SMA + Bollinger Bands (green and yellow lines), linear regression POC and channel tend to provide excellent support and resistance.
Paired with the companion Ticker Pulse Meter + Fear EKG indicator, you’ll visualize sentiment and price dynamics through vibrant area plots and a dynamic heatmap, making every decision crystal-clear. Whether you’re building wealth patiently or capitalizing on market dips, this strategy delivers robust, data-driven signals without the noise. Try it today and elevate your long-term portfolio! Note: Optional visuals (e.g., tables, SMA) use standard Pine Script logic, credited to community practices. Hypothetical results vary; no profits guaranteed.
Visual Enhancers: Entry/exit dots, position table, and optional SMA/Bollinger Bands (if enabled), moving average and linear regression channel use standard Pine Script logic or inspired by public scripts like "Bollinger Bands by TradingView", among others. The visual enhancers are there to provide added context and situational awareness only and are not core to the inter workings of the trading strategy.
None of the above is meant to serve as financial advice and is for educational purposes only.
Please like, comment and follow.
Trend Strategy [BKT]The Trend Strategy is a refined trend-following algorithm designed for intraday traders seeking systematic entries and disciplined exits. It integrates volatility-adjusted levels with directional momentum to identify high-probability trading opportunities during defined trading hours and days.
Bysq-Distance Reversal Entry - BTCUSDT (v6)Strategy Concept
This is a hybrid momentum-reversal strategy for BTC/USDT that combines:
A distance-based momentum approach (original Bysq-style)
A MACD crossover reversal system
The strategy uses technical indicators and statistical distance measurements to identify potential trend reversals and momentum shifts.
Combined Breakout and Divergence SignalsCombined Breakout and Divergence Signals
🧠 Description:
This strategy combines price breakout logic with multi-indicator divergence detection, creating a powerful dual-filtered trading system that identifies high-probability entries. It’s designed to reduce false signals by only acting when both price action confirms a breakout and momentum-based divergence confirms a likely reversal or continuation.
⚙️ Core Logic:
The strategy executes trades only when a breakout is supported by recent divergences detected across a wide set of oscillators and momentum indicators. This dual-layer filtering helps eliminate noise and improves signal quality in trending and ranging markets.
🧩 Strategy Components:
🔺 Breakout Detection:
Identifies bullish breakouts when price exceeds previous high levels from bearish candles.
Detects bearish breakouts when price drops below low levels from bullish candles.
Optional First Arrow Only feature prevents repetitive entries during strong trends.
📉 Divergence Engine:
Scans for both Regular and Hidden divergences.
Supports 10 indicators: MACD, MACD Histogram, RSI, Stochastic, CCI, Momentum, OBV, VWmacd, CMF, MFI.
Flexible input options to customize divergence types, pivot length, max bars, and confirmation logic.
🔗 Combined Logic:
Trades are executed only when a breakout is confirmed by a recent divergence (within a customizable lookback window).
Supports both long and short entries with automatic position closing upon reverse signals.
✅ Features:
📊 10 Momentum & Volume Indicators for divergence confirmation.
🧮 Customizable Pivot Parameters and Divergence Types.
🧠 Adaptive Breakout Filter with trend direction memory.
🎯 Visual markers for Combined Buy/Sell Signals on chart.
🔁 Logical exit rules: trades are only closed upon an opposing signal.
🛠️ Inputs:
Breakout Settings: ATR period, max bars back, first arrow toggle.
Divergence Settings: Pivot period, type, source (Close / High-Low), min divergences required, confirmation toggle.
Indicator Toggles: Enable or disable any divergence indicator individually.
Lookback Control: Number of bars within which divergence must occur to be valid.
Signal Visualization: Custom colors for combined buy/sell arrows.
🎯 Use Cases:
Trend Traders can filter out false breakouts.
Mean Reversion Traders get entry signals backed by weakening momentum.
System Developers can test different indicator combos or divergence types.
🔒 Best Practices:
Use higher timeframes (e.g., 1H, 4H, Daily) for more reliable divergence signals.
Combine with risk management tools (e.g., stop loss, trailing SL) via external script if desired.
Analyze past signals via Strategy Tester to refine breakout/divergence synergy.
🧰 Suggestions for Optimization:
Fine-tune showlimit to balance signal quality vs. quantity.
Disable unused indicators to speed up performance.
Adjust combinedLookback to prevent stale divergences from triggering entries.
📌 This EA is a smart fusion of trend breakout logic and momentum-based divergences, offering a refined signal mechanism with adjustable precision for professional and systematic traders.
DCA StrategyThis strategy makes it easy for you to backtest and automate the DCA strategy based on 2 triggers:
Day of the week
Every X candles
This way you can set up your DCA strategy the way you like and automate on any exchange or even a DEX, which offers an API.
The strategy is auto selling on the last candle, otherwise you won't see any performance numbers because all positions will still be open (non conclusive).
Settings
Start Date & End Date
Use those dates to help you with your backtest period. It also helps when automating, to start at a specific time to mimic what you have already done on your own portfolio and thus be in sync in TV as well.
Capital to invest per trade
Set how capital to use per DCA buy signal. Hover over the tooltip to understand, which currency is used.
Close All on last candle
When backtesting, you must close open positions, otherwise the Strategy Tester won't show you any numbers. This is why the strategy automatically closes all positions on the last candle for your convenience (ON per default).
BUT, when automating, you cannot have this checked because it would sell all of your asset on every candle open. So turn this OFF when automating.
Use Day of Week Mode
This checkbox switches between the "Day of Week" mode or the "Every X Candles" mode.
Day of Week
Opens a long position at the start of the weekday you have set it to.
Hover over the tooltip to understand, which number to use for the day of the week you need.
Every X Candles
Opens a long position after every x candles. Always at the start of every such candle.
On the daily chart, this number represents "1 day", on the 1h chart, it's "1 hour" and so on.
Properties
Initial Capital
DCA has a special quirk and that is that it invests more and more and more funds the longer it runs. But TradingView takes the Initial Capital number to calculate Net Profit, thus the Initial Capital number has to grow with every additional dollar (money) that is being invested over time, otherwise the Net Profit number will be wrong.
Sadly PineScript does not allow to set the Initial Capital number dynamically. So you have to set it manually.
To that end, this strategy shows a Label on the last candle, which shows the Invested Capital. You must take that number and put it into the Initial Capital input and click Ok .
If you don't do this, your Net Profit Number will be totally wrong!
The label must show green .
If it shows red it means you need to change the Initial Capital number before looking at the performance numbers.
After every timeframe or settings change, you must adapt the Initial Capital, otherwise you will get wrong numbers.
Z-Score Normalized VIX StrategyThis strategy leverages the concept of the Z-score applied to multiple VIX-based volatility indices, specifically designed to capture market reversals based on the normalization of volatility. The strategy takes advantage of VIX-related indicators to measure extreme levels of market fear or greed and adjusts its position accordingly.
1. Overview of the Z-Score Methodology
The Z-score is a statistical measure that describes the position of a value relative to the mean of a distribution in terms of standard deviations. In this strategy, the Z-score is calculated for various volatility indices to assess how far their values are from their historical averages, thus normalizing volatility levels. The Z-score is calculated as follows:
Z = \frac{X - \mu}{\sigma}
Where:
• X is the current value of the volatility index.
• \mu is the mean of the index over a specified period.
• \sigma is the standard deviation of the index over the same period.
This measure tells us how many standard deviations the current value of the index is away from its average, indicating whether the market is experiencing unusually high or low volatility (fear or calm).
2. VIX Indices Used in the Strategy
The strategy utilizes four commonly referenced volatility indices:
• VIX (CBOE Volatility Index): Measures the market’s expectations of 30-day volatility based on S&P 500 options.
• VIX3M (3-Month VIX): Reflects expectations of volatility over the next three months.
• VIX9D (9-Day VIX): Reflects shorter-term volatility expectations.
• VVIX (VIX of VIX): Measures the volatility of the VIX itself, indicating the level of uncertainty in the volatility index.
These indices provide a comprehensive view of the current volatility landscape across different time horizons.
3. Strategy Logic
The strategy follows a long entry condition and an exit condition based on the combined Z-score of the selected volatility indices:
• Long Entry Condition: The strategy enters a long position when the combined Z-score of the selected VIX indices falls below a user-defined threshold, indicating an abnormally low level of volatility (suggesting a potential market bottom and a bullish reversal). The threshold is set as a negative value (e.g., -1), where a more negative Z-score implies greater deviation below the mean.
• Exit Condition: The strategy exits the long position when the combined Z-score exceeds the threshold (i.e., when the market volatility increases above the threshold, indicating a shift in market sentiment and reduced likelihood of continued upward momentum).
4. User Inputs
• Z-Score Lookback Period: The user can adjust the lookback period for calculating the Z-score (e.g., 6 periods).
• Z-Score Threshold: A customizable threshold value to define when the market has reached an extreme volatility level, triggering entries and exits.
The strategy also allows users to select which VIX indices to use, with checkboxes to enable or disable each index in the calculation of the combined Z-score.
5. Trade Execution Parameters
• Initial Capital: The strategy assumes an initial capital of $20,000.
• Pyramiding: The strategy does not allow pyramiding (multiple positions in the same direction).
• Commission and Slippage: The commission is set at $0.05 per contract, and slippage is set at 1 tick.
6. Statistical Basis of the Z-Score Approach
The Z-score methodology is a standard technique in statistics and finance, commonly used in risk management and for identifying outliers or unusual events. According to Dumas, Fleming, and Whaley (1998), volatility indices like the VIX serve as a useful proxy for market sentiment, particularly during periods of high uncertainty. By calculating the Z-score, we normalize volatility and quantify the degree to which the current volatility deviates from historical norms, allowing for systematic entry and exit based on these deviations.
7. Implications of the Strategy
This strategy aims to exploit market conditions where volatility has deviated significantly from its historical mean. When the Z-score falls below the threshold, it suggests that the market has become excessively calm, potentially indicating an overreaction to past market events. Entering long positions under such conditions could capture market reversals as fear subsides and volatility normalizes. Conversely, when the Z-score rises above the threshold, it signals increased volatility, which could be indicative of a bearish shift in the market, prompting an exit from the position.
By applying this Z-score normalized approach, the strategy seeks to achieve more consistent entry and exit points by reducing reliance on subjective interpretation of market conditions.
8. Scientific Sources
• Dumas, B., Fleming, J., & Whaley, R. (1998). “Implied Volatility Functions: Empirical Tests”. The Journal of Finance, 53(6), 2059-2106. This paper discusses the use of volatility indices and their empirical behavior, providing context for volatility-based strategies.
• Black, F., & Scholes, M. (1973). “The Pricing of Options and Corporate Liabilities”. Journal of Political Economy, 81(3), 637-654. The original Black-Scholes model, which forms the basis for many volatility-related strategies.
Profit Trailing BBandsProfit Trailing Trend BBands v4.7.5 with Double Trailing SL
A TradingView Pine Script Strategy
Created by Kevin Bourn and refined with the help of Grok 3 (xAI)
Overview
Welcome to Profit Trailing Trend BBands v4.7.5, a dynamic trading strategy designed to ride trends and lock in profits with a unique double trailing stop-loss mechanism. Built for TradingView’s Pine Script v6, this strategy combines Bollinger Bands for trend detection with a smart trailing system that doubles down on profit protection. Whether you’re trading XRP or any other asset, this tool aims to maximize gains while keeping risk in check—all with a clean, visual interface.
What It Does
Identifies Trends: Uses Bollinger Bands to spot uptrends (price crossing above the upper band) and downtrends (price crossing below the lower band).
Enters Positions: Opens long or short trades based on trend signals, with customizable position sizing and leverage.
Trails Profits: Employs a two-stage trailing stop-loss:
Initial Trailing SL: Acts as a take-profit level, set as a percentage (%) or dollar ($) distance from the entry price.
Tightened Trailing SL: Once the initial profit target is hit, the stop-loss tightens to half the initial distance, locking in gains as the trend continues.
Manages Risk: Includes a margin call feature to exit losing positions before they blow up your account.
Visualizes Everything: Plots Bollinger Bands (blue upper, orange lower) and a red stepped trailing stop-loss line for easy tracking.
Why Built It?
Captures Trends: Bollinger Bands are a proven way to catch momentum, and we tuned them for responsiveness (short length, moderate multiplier).
Secures Profits: Traditional trailing stops often leave money on the table or exit too early. The double trailing SL first takes a chunk of profit, then tightens up to ride the rest of the move.
Stays Flexible: Traders can tweak price sources, stop-loss types (% or $), and position sizing to fit their style.
Looks Good: Clear visuals help you see the strategy in action without cluttering your chart.
Originally refined for XRP, it’s versatile enough for most markets — crypto, forex, stocks, you name it.
How It Works
Core Components
Bollinger Bands:
Calculated using a simple moving average (SMA) and standard deviation.
Default settings: 6-period length, 1.66 multiplier.
Upper Band (blue): SMA + (1.66 × StdDev).
Lower Band (orange): SMA - (1.66 × StdDev).
Trend signals: Price crossing above the upper band triggers a long, below the lower band triggers a short.
Double Trailing Stop-Loss:
Initial SL: Set via "Trailing Stop-Loss Value" (default 6% or $6). Trails the price at this distance and doubles as the first profit target.
Tightened SL: Once price hits the initial SL distance in profit (e.g., +6%), the SL tightens to half (e.g., 3%) and continues trailing, locking in gains.
Visualized as a red stepped line, only visible during active positions.
Position Sizing:
Choose "% of Equity" (default 30%) or "Amount in $" to set trade size.
Leverage (default 10x) amplifies positions, capped by available equity to avoid overexposure.
Margin Call:
Exits positions if drawdown exceeds the "Margin %" (default 10%) to protect your account.
Backtesting Filter:
Starts trading after a user-defined date (default: Jan 1, 2020) for focused historical analysis.
Trade Logic
Long Entry: Price crosses above the upper Bollinger Band → Closes any short position, opens a long.
Short Entry: Price crosses below the lower Bollinger Band → Closes any long position, opens a short.
Exit: Position closes when price hits the trailing stop-loss or triggers a margin call.
How to Use It
Setup
Add to TradingView:
Open TradingView, go to the Pine Editor, paste the script, and click "Add to Chart."
Ensure you’re using Pine Script v6 (the script includes @version=6).
Configure Inputs:
Start Date for Backtesting: Set the date to begin historical testing (default: Jan 1, 2020).
BB Length & Mult: Adjust Bollinger Band sensitivity (default: 6, 1.66).
BB Price Source: Choose the price for BBands (default: Close).
Trend Price Source: Choose the price for trend detection (default: Close).
Trailing Stop-Loss Type: Pick "%" or "$" (default: Trailing SL %).
Trailing Stop-Loss Value: Set the initial SL distance (default: 6).
Margin %: Define the max drawdown before exit (default: 10%).
Order Size Type & Value: Set position size as % of equity (default: 30%) or $ amount.
Leverage: Adjust leverage (default: 10x).
Run It:
Use the Strategy Tester tab to backtest on your chosen asset and timeframe.
Watch the chart for blue/orange Bollinger Bands and the red trailing SL line.
Tips for Traders
Timeframes: Works on any timeframe, but test 1H or 4H for XRP—great balance of signals and noise.
Assets: Optimized for XRP, but tweak slValue and mult for other markets (e.g., tighter SL for low-volatility pairs).
Risk Management: Keep marginPercent low (5-10%) for volatile assets; adjust leverage based on your risk tolerance.
Visuals: The red stepped SL line shows only during trades—zoom in to see its tightening in action.
Visuals on the Chart
Blue Line: Upper Bollinger Band (trend entry for longs).
Orange Line: Lower Bollinger Band (trend entry for shorts).
Red Stepped Line: Trailing Stop-Loss (shifts tighter after the first profit target).
Order Labels: Short tags like "OL" (Open Long), "CS" (Close Short), "LSL" (Long Stop-Loss), etc., mark trades.
Disclaimer
Trading involves risk. This strategy is for educational and experimental use—backtest thoroughly and use at your own risk. Past performance doesn’t guarantee future results. Not financial advice—just a tool from traders, for traders.
Cycle Biologique Strategy // (\_/)
// ( •.•)
// (")_(")
//@fr33domz
Experimental Research: Cycle Biologique Strategy
Overview
The "Cycle Biologique Strategy" is an experimental trading algorithm designed to leverage periodic cycles in price movements by utilizing a sinusoidal function. This strategy aims to identify potential buy and sell signals based on the behavior of a custom-defined biological cycle.
Key Parameters
Cycle Length: This parameter defines the duration of the cycle, set by default to 30 periods. The user can adjust this value to optimize the strategy for different asset classes or market conditions.
Amplitude: The amplitude of the cycle influences the scale of the sinusoidal wave, allowing for customization in the sensitivity of buy and sell signals.
Offset: The offset parameter introduces phase shifts to the cycle, adjustable within a range of -360 to 360 degrees. This flexibility allows the strategy to align with various market rhythms.
Methodology
The core of the strategy lies in the calculation of a periodic cycle using a sinusoidal function.
Trading Signals
Buy Signal: A buy signal is generated when the cycle value crosses above zero, indicating a potential upward momentum.
Sell Signal: Conversely, a sell signal is triggered when the cycle value crosses below zero, suggesting a potential downtrend.
Execution
The strategy executes trades based on these signals:
Upon receiving a buy signal, the algorithm enters a long position.
When a sell signal occurs, the strategy closes the long position.
Visualization
To enhance user experience, the periodic cycle is plotted visually on the chart in blue, allowing traders to observe the cyclical nature of the strategy and its alignment with market movements.
Strategy Stats [presentTrading]Hello! it's another weekend. This tool is a strategy performance analysis tool. Looking at the TradingView community, it seems few creators focus on this aspect. I've intentionally created a shared version. Welcome to share your idea or question on this.
█ Introduction and How it is Different
Strategy Stats is a comprehensive performance analytics framework designed specifically for trading strategies. Unlike standard strategy backtesting tools that simply show cumulative profits, this analytics suite provides real-time, multi-timeframe statistical analysis of your trading performance.
Multi-timeframe analysis: Automatically tracks performance metrics across the most recent time periods (last 7 days, 30 days, 90 days, 1 year, and 4 years)
Advanced statistical measures: Goes beyond basic metrics to include Information Coefficient (IC) and Sortino Ratio
Real-time feedback: Updates performance statistics with each new trade
Visual analytics: Color-coded performance table provides instant visual feedback on strategy health
Integrated risk management: Implements sophisticated take profit mechanisms with 3-step ATR and percentage-based exits
BTCUSD Performance
The table in the upper right corner is a comprehensive performance dashboard showing trading strategy statistics.
Note: While this presentation uses Vegas SuperTrend as the underlying strategy, this is merely an example. The Stats framework can be applied to any trading strategy. The Vegas SuperTrend implementation is included solely to demonstrate how the analytics module integrates with a trading strategy.
⚠️ Timeframe Limitations
Important: TradingView's backtesting engine has a maximum storage limit of 10,000 bars. When using this strategy stats framework on smaller timeframes such as 1-hour or 2-hour charts, you may encounter errors if your backtesting period is too long.
Recommended Timeframe Usage:
Ideal for: 4H, 6H, 8H, Daily charts and above
May cause errors on: 1H, 2H charts spanning multiple years
Not recommended for: Timeframes below 1H with long history
█ Strategy, How it Works: Detailed Explanation
The Strategy Stats framework consists of three primary components: statistical data collection, performance analysis, and visualization.
🔶 Statistical Data Collection
The system maintains several critical data arrays:
equityHistory: Tracks equity curve over time
tradeHistory: Records profit/loss of each trade
predictionSignals: Stores trade direction signals (1 for long, -1 for short)
actualReturns: Records corresponding actual returns from each trade
For each closed trade, the system captures:
float tradePnL = strategy.closedtrades.profit(tradeIndex)
float tradeReturn = strategy.closedtrades.profit_percent(tradeIndex)
int tradeType = entryPrice < exitPrice ? 1 : -1 // Direction
🔶 Performance Metrics Calculation
The framework calculates several key performance metrics:
Information Coefficient (IC):
The correlation between prediction signals and actual returns, measuring forecast skill.
IC = Correlation(predictionSignals, actualReturns)
Where Correlation is the Pearson correlation coefficient:
Correlation(X,Y) = (nΣXY - ΣXY) / √
Sortino Ratio:
Measures risk-adjusted return focusing only on downside risk:
Sortino = (Avg_Return - Risk_Free_Rate) / Downside_Deviation
Where Downside Deviation is:
Downside_Deviation = √
R_i represents individual returns, T is the target return (typically the risk-free rate), and n is the number of observations.
Maximum Drawdown:
Tracks the largest percentage drop from peak to trough:
DD = (Peak_Equity - Trough_Equity) / Peak_Equity * 100
🔶 Time Period Calculation
The system automatically determines the appropriate number of bars to analyze for each timeframe based on the current chart timeframe:
bars_7d = math.max(1, math.round(7 * barsPerDay))
bars_30d = math.max(1, math.round(30 * barsPerDay))
bars_90d = math.max(1, math.round(90 * barsPerDay))
bars_365d = math.max(1, math.round(365 * barsPerDay))
bars_4y = math.max(1, math.round(365 * 4 * barsPerDay))
Where barsPerDay is calculated based on the chart timeframe:
barsPerDay = timeframe.isintraday ?
24 * 60 / math.max(1, (timeframe.in_seconds() / 60)) :
timeframe.isdaily ? 1 :
timeframe.isweekly ? 1/7 :
timeframe.ismonthly ? 1/30 : 0.01
🔶 Visual Representation
The system presents performance data in a color-coded table with intuitive visual indicators:
Green: Excellent performance
Lime: Good performance
Gray: Neutral performance
Orange: Mediocre performance
Red: Poor performance
█ Trade Direction
The Strategy Stats framework supports three trading directions:
Long Only: Only takes long positions when entry conditions are met
Short Only: Only takes short positions when entry conditions are met
Both: Takes both long and short positions depending on market conditions
█ Usage
To effectively use the Strategy Stats framework:
Apply to existing strategies: Add the performance tracking code to any strategy to gain advanced analytics
Monitor multiple timeframes: Use the multi-timeframe analysis to identify performance trends
Evaluate strategy health: Review IC and Sortino ratios to assess predictive power and risk-adjusted returns
Optimize parameters: Use performance data to refine strategy parameters
Compare strategies: Apply the framework to multiple strategies to identify the most effective approach
For best results, allow the strategy to generate sufficient trade history for meaningful statistical analysis (at least 20-30 trades).
█ Default Settings
The default settings have been carefully calibrated for cryptocurrency markets:
Performance Tracking:
Time periods: 7D, 30D, 90D, 1Y, 4Y
Statistical measures: Return, Win%, MaxDD, IC, Sortino Ratio
IC color thresholds: >0.3 (green), >0.1 (lime), <-0.1 (orange), <-0.3 (red)
Sortino color thresholds: >1.0 (green), >0.5 (lime), <0 (red)
Multi-Step Take Profit:
ATR multipliers: 2.618, 5.0, 10.0
Percentage levels: 3%, 8%, 17%
Short multiplier: 1.5x (makes short take profits more aggressive)
Stop loss: 20%
External Signals Strategy TesterExternal Signals Strategy Tester
This strategy is designed to help you backtest external buy/sell signals coming from another indicator on your chart. It is a flexible and powerful tool that allows you to simulate real trading based on signals generated by any indicator, using input.source connections.
🔧 How It Works
Instead of generating signals internally, this strategy listens to two external input sources:
One for buy signals
One for sell signals
These sources can be connected to the plots from another indicator (for example, custom indicators, signal lines, or logic-based plots).
To use this:
Add your indicator to the chart (it must be visible on the same pane as this strategy).
Open the settings of the strategy.
In the fields Buy Signal and Sell Signal, select the appropriate plot (line, value, etc.) from the indicator that represents the buy/sell logic.
The strategy will open positions when the selected buy signal crosses above 0, and sell signal crosses above 0.
This logic can be easily adapted by modifying the crossover rule inside the script if your signal style is different.
⚙️ Features Included
✅ Configurable trade direction:
You can choose whether to allow long trades, short trades, or both.
✅ Optional close on opposite signal:
When enabled, the strategy will exit the current position if an opposite signal appears.
✅ Optional full position reversal:
When enabled, the strategy will close the current position and immediately open an opposite one on the reverse signal.
✅ Risk Management Tools:
You can define:
Take Profit (TP): Position will be closed once the specified profit (in %) is reached.
Stop Loss (SL): Position will be closed if the price drops to the specified loss level (in %).
BreakEven (BE): Once the specified profit threshold is reached, the strategy will move the stop-loss to the entry price.
📌 If any of these values (TP, SL, BE) are set to 0, the feature is disabled and will not be applied.
🧪 Best Use Cases
Backtesting signals from custom indicators, without rewriting the logic into a strategy.
Comparing the performance of different signal sources.
Testing external indicators with optional position management logic.
Validating strategies using external filters, oscillators, or trend signals.
📌 Final Notes
You can visualize where the strategy detected buy/sell signals using green/red markers on the chart.
All parameters are customizable through the strategy settings panel.
This strategy does not repaint, and it processes signals in real-time only (no lookahead bias).
EMA 10/55/200 - LONG ONLY MTF (4h with 1D & 1W confirmation)Title: EMA 10/55/200 - Long Only Multi-Timeframe Strategy (4h with 1D & 1W confirmation)
Description:
This strategy is designed for trend-following long entries using a combination of exponential moving averages (EMAs) on the 4-hour chart, confirmed by higher timeframe trends from the daily (1D) and weekly (1W) charts.
🔍 How It Works
🔹 Entry Conditions (4h chart):
EMA 10 crosses above EMA 55 and price is above EMA 55
OR
EMA 55 crosses above EMA 200
OR
EMA 10 crosses above EMA 500
These entries indicate short-term momentum aligning with medium/long-term trend strength.
🔹 Confirmation (multi-timeframe alignment):
Daily (1D): EMA 55 is above EMA 200
Weekly (1W): EMA 55 is above EMA 200
This ensures that we only enter long trades when the higher timeframes support an uptrend, reducing false signals during sideways or bearish markets.
🛑 Exit Conditions
Bearish crossover of EMA 10 below EMA 200 or EMA 500
Stop Loss: 5% below entry price
⚙️ Backtest Settings
Capital allocation per trade: 10% of equity
Commission: 0.1%
Slippage: 2 ticks
These are realistic conditions for crypto, forex, and stocks.
📈 Best Used On
Timeframe: 4h
Instruments: Trending markets like BTC/ETH, FX majors, or growth stocks
Works best in volatile or trending environments
⚠️ Disclaimer
This is a backtest tool and educational resource. Always validate on demo accounts before applying to real capital. Do your own due diligence.
Buy on 5% dip strategy with time adjustment
This script is a strategy called "Buy on 5% Dip Strategy with Time Adjustment 📉💡," which detects a 5% drop in price and triggers a buy signal 🔔. It also automatically closes the position once the set profit target is reached 💰, and it has additional logic to close the position if the loss exceeds 14% after holding for 230 days ⏳.
Strategy Explanation
Buy Condition: A buy signal is triggered when the price drops 5% from the highest price reached 🔻.
Take Profit: The position is closed when the price hits a 1.22x target from the average entry price 📈.
Forced Sell Condition: If the position is held for more than 230 days and the loss exceeds 14%, the position is automatically closed 🚫.
Leverage & Capital Allocation: Leverage is adjustable ⚖️, and you can set the percentage of capital allocated to each trade 💸.
Time Limits: The strategy allows you to set a start and end time ⏰ for trading, making the strategy active only within that specific period.
Code Credits and References
Credits: This script utilizes ideas and code from @QuantNomad and jangdokang for the profit table and algorithm concepts 🔧.
Sources:
Monthly Performance Table Script by QuantNomad:
ZenAndTheArtOfTrading's Script:
Strategy Performance
This strategy provides risk management through take profit and forced sell conditions and includes a performance table 📊 to track monthly and yearly results. You can compare backtest results with real-time performance to evaluate the strategy's effectiveness.
The performance numbers shown in the backtest reflect what would have happened if you had used this strategy since the launch date of the SOXL (the Direxion Daily Semiconductor Bull 3x Shares ETF) 📅. These results are not hypothetical but based on actual performance from the day of the ETF’s launch 📈.
Caution ⚠️
No Guarantee of Future Results: The results are based on historical performance from the launch of the SOXL ETF, but past performance does not guarantee future results. It’s important to approach with caution when applying it to live trading 🔍.
Risk Management: Leverage and capital allocation settings are crucial for managing risk ⚠️. Make sure to adjust these according to your risk tolerance ⚖️.