Engulfing Candle Pattern (Strict)Indicator Name :
Engulfing Candle Pattern (Strict)
Purpose :
The Engulfing Candle Pattern Indicator is designed to identify and visually mark bullish and bearish engulfing patterns on a price chart. These patterns are powerful reversal signals in technical analysis, often used by traders to spot potential trend changes. The indicator ensures strict adherence to the definition of engulfing patterns, making it reliable for identifying high-probability setups.
What It Does :
Identifies Engulfing Patterns :
The indicator scans the price data for candles that meet the criteria of either a bullish engulfing or bearish engulfing pattern .
A bullish engulfing occurs when a green (bullish) candle fully engulfs the body and wicks of the previous red (bearish) candle and closes above its high.
A bearish engulfing occurs when a red (bearish) candle fully engulfs the body and wicks of the previous green (bullish) candle and closes below its low.
Marks Patterns Visually :
Bullish engulfing patterns are marked with a green upward triangle below the candle.
Bearish engulfing patterns are marked with a red downward triangle above the candle.
Optional labels ("Bullish" or "Bearish") provide additional context.
Highlights Candles :
Engulfing candles are highlighted with semi-transparent colors:
Green for bullish engulfing.
Red for bearish engulfing.
Ensures Strict Conditions :
The current candle must fully cover the entire body and wicks of the previous candle.
The current candle must close above the previous candle's high (for bullish) or below the previous candle's low (for bearish).
Indicateurs et stratégies
Bi Trend signalauto bot MT5 for XAU, BTC ETH, liên hệ tôi để biết thêm chi tiết cho các hạng mục coppy trade
MTF EMA 20 Overlay (15m / 30m / 1h)📌 Multi-Timeframe EMA 20 Overlay — Perfect for scalping and trend-following traders.
This script displays the 20 EMA from 15-minute, 30-minute, and 1-hour timeframes directly on your current chart (e.g., 5-minute).
🟢 15m EMA 20 — Short-term confirmation
🟠 30m EMA 20 — Mid-level support/resistance
🔴 1h EMA 20 — Major trend guide
💡 Ideal for:
• Spotting key pullback zones
• Identifying intraday trend strength
• Aligning lower timeframe entries with higher timeframe structure
🎯 Strategy Tip:
Longs are higher probability when price is above the 15m/30m/1h EMAs. Watch for rejections or bounces near these levels.
Created with ❤️ by @little swiss + ChatGPT support.
111D SMA / (350D SMA * 2)Indicator: Pi Cycle Ratio
This custom technical indicator calculates a ratio between two moving averages that are used for the PI Cycle Top indicator. The PI Cycle Top indicator triggers when the 111-day simple moving average (111D SMA) crosses up with the 350-day simple moving average (350D SMA *2).
The line value is ratio is calculated as:
Line Value = 111DSMA / (350D SMA × 2)
When the 111D SMA crosses with the 350D SMA triggering the PI Cycle Top, the value of the ratio between the two lines is 1.
This visualizes the ratio between the two moving averages into a single line. This indicator can be used for technical analysis for historical and future moves.
Elliott Wave Identification By Akash Patel
This script is designed to visually highlight areas on the chart where there are consecutive bullish (green) or bearish (red) candles. It also identifies sequences of three consecutive candles of the same type (bullish or bearish) and highlights those areas with adjustable box opacity. Here's a breakdown of the functionality:
---
### Key Features:
1. **Bullish & Bearish Candle Identification:**
- **Bullish Candle:** When the closing price is higher than the opening price (`close > open`).
- **Bearish Candle:** When the closing price is lower than the opening price (`close < open`).
2. **Consecutive Candle Counter:**
- The script counts consecutive bullish and bearish candles, which resets when the direction changes (from bullish to bearish or vice versa).
- The script tracks these counts using the `bullishCount` and `bearishCount` variables, which are incremented based on whether the current candle is bullish or bearish.
3. **Highlighting Candle Areas:**
- If there are **3 or more consecutive bullish candles**, the script will highlight the background in a green color with 90% transparency (adjustable).
- Similarly, if there are **3 or more consecutive bearish candles**, the script will highlight the background in a red color with 90% transparency (adjustable).
4. **Three-Candle Sequence:**
- The script checks if there are three consecutive bullish candles (`threeBullish`) or three consecutive bearish candles (`threeBearish`).
- A box is drawn around these areas to visually highlight the sequence. The boxes extend to the right edge of the chart, and their opacity can be adjusted.
5. **Box Creation:**
- For bullish sequences, a green box is created using the high and low prices of the three candles in the sequence.
- For bearish sequences, a red box is created in the same manner.
- The box size is determined by the highest high and the lowest low of the three consecutive candles.
6. **Box Opacity:**
- You can adjust the opacity of the boxes through the input parameters `Bullish Box Opacity` and `Bearish Box Opacity` (ranging from 0 to 100).
- A higher opacity will make the boxes more solid, while a lower opacity will make them more transparent.
7. **Box Cleanup:**
- The script also includes logic to remove boxes when they are no longer needed, ensuring the chart remains clean without excessive box overlays.
8. **Extending Boxes to the Right:**
- When a bullish or bearish sequence is identified, the boxes are extended to the right edge of the chart for continued visibility.
---
### How It Works:
- **Bullish Area Highlight:** When three or more consecutive bullish candles are detected, the background will turn green to indicate a strong bullish trend.
- **Bearish Area Highlight:** When three or more consecutive bearish candles are detected, the background will turn red to indicate a strong bearish trend.
- **Three Consecutive Candle Box:** A green box will appear around three consecutive bullish candles, and a red box will appear around three consecutive bearish candles. These boxes can be extended to the right edge of the chart, making the sequence visually clear.
---
### Adjustable Parameters:
1. **Bullish Box Opacity:** Set the opacity (transparency) level of the bullish boxes. Ranges from 0 (completely transparent) to 100 (completely opaque).
2. **Bearish Box Opacity:** Set the opacity (transparency) level of the bearish boxes. Ranges from 0 (completely transparent) to 100 (completely opaque).
---
This indicator is useful for identifying strong trends and visually confirming market momentum, especially in situations where you want to spot sequences of bullish or bearish candles over multiple bars. It can be customized to suit different trading styles and chart preferences by adjusting the opacity of the boxes and background highlights.
Hossa Sweep/liquidityHossa Sweep/Liquidity – How It Works and How to Use It
The Hossa Sweep/Liquidity indicator is designed to detect “sweep” signals across multiple timeframes. A “sweep” occurs when one candle (Candle #2) pushes beyond the previous candle’s high or low (Candle #1) while both candles share the same color (both bullish or both bearish). Additionally, Candle #1 must have a visible wick. This indicator can help traders identify potential turning points or continuation patterns.
1. How It Operates for Traders
Multiple Timeframes: You can select up to five different timeframes (e.g., 5m, 15m, 1H, 4H, 1D). The indicator will check each chosen timeframe to see if a sweep is happening.
Visual Labels: When it detects a valid sweep:
SL (Sweep Long) label appears below a candle if the sweep is bullish.
SS (Sweep Short) label appears above a candle if the sweep is bearish.
Alerts: The script triggers an alert whenever a new sweep signal appears on any of the selected timeframes, so you won’t miss an opportunity.
2. Practical Ways to Use It
Confluence with Other Signals
Combine these sweep signals with your favorite support/resistance zones, moving averages, or volume profiles. For instance, a sweep at a known support zone can hint at a bullish reversal; a sweep at resistance might suggest a bearish reversal.
Confirm Trend Continuations
Watch for bullish sweeps in an existing uptrend or bearish sweeps in a downtrend. A sweep in line with the overall trend can serve as a continuation signal, helping you time pullback entries.
Identify Potential Reversals
Sweeps often appear near market tops/bottoms when price aggressively tests a previous candle’s high or low. In these areas, a sweep followed by strong follow-through can be a clue of a likely turning point.
Manage Risk More Precisely
Since the indicator specifies exact candle highs/lows, you can plan tighter stop-loss levels or be more precise with your targets.
Request to Share My Work
Dear Users,
I kindly ask for your support in sharing my work with your friends and networks. Every like, share, or recommendation is extremely valuable to me and helps reach a wider audience.
I would be immensely grateful for any form of support and engagement! Thanks to your help, I can continue developing this project and bring more ideas to life.
With sincere appreciation,
MACD Crossover IndicatorSimple MACD "Crossover" script. This indicator shows a symbol of your choice "+" on the chart when signal line crosses over the MACD.
Settings can be adjusted like the MACD indicator. This is helpeful as sometimes it can be hard to see when it actually crosses over.
Higher Highs, Higher Lows, Lower Highs, Lower Lowsshows Higher Highs and Higher Lows, and Lower Highs and Lower Lows
Barras de resiliencia contra el mercadoRelative strength vs market indicator
🎯 main goal:
To visually detect when a stock shows relative strength against the S&P 500, especially on down days in the market. The indicator helps identify stocks that:
Go up while the SP500 goes down
Fall less than the SP500
🟩 solid green bar (upward)
Condition: SP500 closes negative, your stock closes positive.
Color: solid green
Meaning: strong relative strength. The stock goes up while the market drops.
Example:
SP500: -1.2%
Stock: +1.5%
Difference: +2.7% → green bar going up
🟧 light orange bar (upward)
Condition: SP500 closes negative, your stock also drops, but less than the SP500.
Color: light orange
Meaning: resilience. Still a down day, but the stock shows relative strength.
Example:
SP500: -2.0%
Stock: -0.5%
Difference: +1.5% → light orange bar going up
🟥 red bar (downward)
Condition: SP500 closes negative, your stock drops more than the index.
Color: solid red
Meaning: clear weakness. The stock is underperforming in a weak market.
Example:
SP500: -0.8%
Stock: -2.0%
Difference: -1.2% → red bar going down
🟩 light green bar (upward)
Condition: SP500 closes positive, your stock outperforms the index (goes up more).
Color: light green (50% opacity)
Meaning: relative strength in a strong market. Not as critical, but still positive.
Example:
SP500: +0.5%
Stock: +1.5%
Difference: +1.0% → light green bar going up
🟩 light green bar (downward)
Condition: SP500 closes positive, but your stock underperforms (gains less or even drops).
Color: light green (50% opacity)
Meaning: underperformance on a strong day. The stock lags the index.
Example 1:
SP500: +1.8%
Stock: +0.5%
Difference: -1.3% → light green bar going down
Example 2:
SP500: +1.0%
Stock: -0.5%
Difference: -1.5% → light green bar going down
OG QQE ModDescription:
The QQE MOD is a modernized version of the classic QQE (Quantitative Qualitative Estimation) momentum oscillator, refined for real-time decision-making in today’s volatile markets.
How it works:
Measures smoothed RSI changes with a dynamic trailing stop system.
Provides early momentum shifts and trend continuation signals.
Color-coded zones signal potential buy/sell momentum strength.
Best for:
Momentum-based entries in breakout or continuation trades.
Detecting reversals before traditional indicators confirm.
Works well on crypto, indices, and fast-moving assets.
Pro Tip: Use in combination with trend filters like Supertrend or EMA stack to avoid countertrend traps.
Wick Sweep EntriesThis 2 Candle Setup is designed by Finweal Finance, This Setup suggests the HFT Setup for Instant entry on 5min candles.
Hossa SignalsHow It Works
The "Hossa Signals" indicator generates trading signals based on four distinct strategy modes:
Mode 1 & 2 (Counter Trade Strategies):
These modes trigger buy signals when the price falls below a moving average (SMA50 for Mode 1, SMA200 for Mode 2) combined with a low RSI (having been below 26), and sell signals when the price rises above these SMAs combined with a high RSI (previously above 74).
Mode 3 & 4 (Trend Respect Strategies):
These modes generate buy signals when the price crosses above the respective moving average (SMA50 for Mode 3, SMA200 for Mode 4) and the RSI is strong (above 55 after touching 50), and sell signals when the price crosses below these levels with the RSI dropping below 45.
Additional conditions for taking profit are built into each mode, and the indicator tracks position status to help reset the conditions after a trade is closed.
Signals are plotted directly on the chart with labels (displaying "KUP" for buy and "SPRZEDAJ" for sell) and shapes for visual clarity. The current RSI value is also shown in the top-right corner.
How to Use It
Trade Entry:
For example, in Mode 1, if the price dips below SMA50, the RSI has been low (below 26) and is now rising above 30, a buy signal is generated. This may signal a counter-trend opportunity when the price has oversold.
Trade Exit:
Conversely, if the price rises above SMA50 while the RSI is falling (having been high above 74 and now dropping below 70), a sell signal is generated to exit the trade.
Risk Management:
Take profit (TP) conditions are set based on price action or RSI levels. These conditions help you exit a trade once the market moves in your favor, ensuring you lock in profits.
Example Strategy
Counter-Trend Setup (Mode 1):
Buy: Enter a long position when the price drops below the 50-period SMA and the RSI has been oversold (below 26) but starts to recover (rises above 30).
Sell/TP: Exit when the price moves above the SMA or the RSI reaches a high level (above 70).
Trend Respect Setup (Mode 3):
Buy: Enter when the price crosses above the 50-period SMA and the RSI, after touching around 50, moves up above 55.
Sell/TP: Exit when the price reverses (crosses below the SMA) or the RSI drops below 45.
Combine this indicator with other analysis tools (like volume or support/resistance levels) to refine your entry and exit points.
Please Share
If you find the "Hossa Signals" indicator useful for your trading strategy, please share it with your fellow traders. Sharing helps grow our community and encourages the development of more innovative trading tools.
Enjoy your trading!
Premarket High/Low Breakout Alert (SMA8 Filter)Premarket HIgh Low Alert with 8SMA filter
Premarket HIgh Low Alert with 8SMA filter
Premarket HIgh Low Alert with 8SMA filter
Premarket HIgh Low Alert with 8SMA filter
Premarket HIgh Low Alert with 8SMA filter
PowerZone Trading StrategyExplanation of the PowerZone Trading Strategy for Your Users
The PowerZone Trading Strategy is an automated trading strategy that detects strong price movements (called "PowerZones") and generates signals to enter a long (buy) or short (sell) position, complete with predefined take profit and stop loss levels. Here’s how it works, step by step:
1. What is a PowerZone?
A "PowerZone" (PZ) is a zone on the chart where the price has shown a significant and consistent movement over a specific number of candles (bars). There are two types:
Bullish PowerZone (Bullish PZ): Occurs when the price rises consistently over several candles after an initial bearish candle.
Bearish PowerZone (Bearish PZ): Occurs when the price falls consistently over several candles after an initial bullish candle.
The code analyzes:
A set number of candles (e.g., 5, adjustable via "Periods").
A minimum percentage move (adjustable via "Min % Move for PowerZone") to qualify as a strong zone.
Whether to use the full candle range (highs and lows) or just open/close prices (toggle with "Use Full Range ").
2. How Does It Detect PowerZones?
Bullish PowerZone:
Looks for an initial bearish candle (close below open).
Checks that the next candles (e.g., 5) are all bullish (close above open).
Ensures the total price movement exceeds the minimum percentage set.
Defines a range: from the high (or open) to the low of the initial candle.
Bearish PowerZone:
Looks for an initial bullish candle (close above open).
Checks that the next candles are all bearish (close below open).
Ensures the total price movement exceeds the minimum percentage.
Defines a range: from the high to the low (or close) of the initial candle.
These zones are drawn on the chart with lines: green or white for bullish, red or blue for bearish, depending on the color scheme ("DARK" or "BRIGHT").
3. When Does It Enter a Trade?
The strategy waits for a breakout from the PowerZone range to enter a trade:
Buy (Long): When the price breaks above the high of a Bullish PowerZone.
Sell (Short): When the price breaks below the low of a Bearish PowerZone.
The position size is set to 100% of available equity (adjustable in the code).
4. Take Profit and Stop Loss
Take Profit (TP): Calculated as a multiple (adjustable via "Take Profit Factor," default 1.5) of the PowerZone height. For example:
For a buy, TP = Entry price + (PZ height × 1.5).
For a sell, TP = Entry price - (PZ height × 1.5).
Stop Loss (SL): Calculated as a multiple (adjustable via "Stop Loss Factor," default 1.0) of the PZ height, placed below the range for buys or above for sells.
5. Visualization on the Chart
PowerZones are displayed with lines on the chart (you can hide them with "Show Bullish Channel" or "Show Bearish Channel").
An optional info panel ("Show Info Panel") displays key levels: PZ high and low, TP, and SL.
You can also enable brief documentation on the chart ("Show Documentation") explaining the basic rules.
6. Alerts
The code generates automatic alerts in TradingView:
For a bullish breakout: "Bullish PowerZone Breakout - LONG!"
For a bearish breakdown: "Bearish PowerZone Breakdown - SHORT!"
7. Customization
You can tweak:
The number of candles to detect a PZ ("Periods").
The minimum percentage move ("Min % Move").
Whether to use highs/lows or just open/close ("Use Full Range").
The TP and SL factors.
The color scheme and what elements to display on the chart.
Practical Example
Imagine you set "Periods = 5" and "Min % Move = 2%":
An initial bearish candle appears, followed by 5 consecutive bullish candles.
The total move exceeds 2%.
A Bullish PowerZone is drawn with a high and low.
If the price breaks above the high, you enter a long position with a TP 1.5 times the PZ height and an SL equal to the height below.
The system executes the trade and exits automatically at TP or SL.
Conclusion
This strategy is great for capturing strong price movements after consolidation or momentum zones. It’s automated, visual, and customizable, making it useful for both beginner and advanced traders. Try it out and adjust it to fit your trading style!
Vikrant Premium Lux AlgoVikrant Lux Indicator .
💠 THIS INDICATOR IS FOR LAPTOP or PC OR MOBILE
💠TO USE THIS INDICATOR NO NEED ANY CANDLE & TECHNICAL KNOWLEDGE💠
💠FOR ALL SEGMENT CASH, FUTURE, INDEX, OPTIONS, FOREX & CRYPTO,ALL OVER WORLD STOCK💠
💠FOR SCALPING+INTRADAY+POSITIONAL+BTST+DELEVRY+JACKPOT CALL 💠
💠ACCURACY LEVEL- 90 %💠
💠FRIST UNDERSTAND ENTRY EXIT POINT AFTER TRADE IN LIVE MARKET💠
💠INVEST SOME MONEY FOR GOOD ACCURATE SET UP & EARN DAILY 💠
🤑🤑🤑🤑🤑🤑🤑🤑🤑🤑
DON'T DEPEND ANY TIPS PROVIDER SERVICE ... DON'T LOSS YOUR HARDWORK MONEY
Become independent traders don't depends any tips service company
JOIN NOW TODAY on Telegram - t.me
Contact For more information on - 9689328585/8454841008
Lumen Auto Long - TEST Triggerstrategy("Lumen Auto Long - TEST Trigger", overlay=true, default_qty_type=strategy.percent_of_equity, default_qty_value=100)
rsi = ta.rsi(close, 14)
entry_condition = rsi < 100
Three Flexible Volume Profiles3 Flex volume - Adjustment through bars
Volume Profile is Horizontal
✅ Bar-to-Bar Selection Added (Choose start_bar & end_bar)
✅ Date & Time Selection Available (Choose start_time & end_time)
✅ Fixed box.new Syntax
✅ Fixed maxVol Undefined Issue
✅ Optimized Calculation for Large Data Sets
This will display a flexible horizontal volume profile for a user-selected range with proper value area (VAH, VAL) and POC. 🎯 Let me know if you need tweaks! 🚀
WMA and Intraday Highest Volume Candle Levels🔹 WMA Calculation (Weighted Moving Averages)
Custom WMA Function:
Uses a manual weighted average calculation.
Assigns more weight to recent prices for smoother trend detection.
Three Timeframes:
5-Minute WMA (Yellow)
15-Minute WMA (Blue)
30-Minute WMA (Red)
🔹 Intraday Highest Volume Candle Levels
Finds the candle with the highest volume for the selected intraday timeframe.
Stores its High & Low levels to act as support/resistance.
Deletes and redraws lines daily to reflect the latest session's highest volume candle.
Plots horizontal lines:
Green Line: High of the highest volume candle.
Red Line: Low of the highest volume candle.
Customization: User can choose the analysis timeframe (default: 3 minutes).
✅ Benefits of This Indicator
✔ Multi-timeframe trend analysis using WMA.
✔ Key intraday levels based on highest volume candle.
✔ Dynamic support & resistance levels based on real-time volume activity.
✔ Customizable timeframe for volume analysis.
Long Term Profitable Swing | AbbasA Story of a Profitable Swing Trading Strategy
Imagine you're sailing across the ocean, looking for the perfect wave to ride. Swing trading is quite similar—you're navigating the stock market, searching for the ideal moments to enter and exit trades. This strategy, created by Abbas, helps you find those waves and ride them effectively to profitable outcomes.
🌊 Finding the Perfect Wave (Entry)
Our journey begins with two simple signs that tell us a great trading opportunity is forming:
- Moving Averages: We use two lines that follow price trends—the faster one (EMA 16) reacts quickly to recent price moves, and the slower one (EMA 30) gives us a longer-term perspective. When the faster line crosses above the slower line, it's like a clear signal saying, "Hey! The wave is rising, and prices might move higher!"
- RSI Momentum: Next, we check a tool called the RSI, which measures momentum (how strongly prices are moving). If the RSI number is above 50, it means there's enough strength behind this rising wave to carry us forward.
When both signals appear together, that's our green light. It's time to jump on our surfboard and start riding this promising wave.
⚓ Safely Riding the Wave (Risk Management)
While we're riding this wave, we want to ensure we're safe from sudden surprises. To do this, we use something called the Average True Range (ATR), which measures how volatile (or bumpy) the price movements are:
- Stop-Loss: To avoid falling too hard, we set a safety line (stop-loss) 8 times the ATR below our entry price. This helps ensure we exit if the wave suddenly turns against us, protecting us from heavy losses.
- Take Profit: We also set a goal to exit the trade at 11 times the ATR above our entry. This way, we capture significant profits when the wave reaches a nice high point.
🌟 Multiple Rides, Bigger Adventures
This strategy allows us to take multiple positions simultaneously—like riding several waves at once, up to 5. Each trade we make uses only 10% of our trading capital, keeping risks manageable and giving us multiple opportunities to win big.
🗺️ Easy to Follow Settings
Here are the basic settings we use:
- Fast EMA**: 16
- Slow EMA**: 30
- RSI Length**: 9
- RSI Threshold**: 50
- ATR Length**: 21
- ATR Stop-Loss Multiplier**: 8
- ATR Take-Profit Multiplier**: 11
These settings are flexible—you can adjust them to better suit different markets or your personal trading style.
🎉 Riding the Waves of Success
This simple yet powerful swing trading approach helps you confidently enter trades, clearly know when to exit, and effectively manage your risk. It’s a reliable way to ride market waves, capture profits, and minimize losses.
Happy trading, and may you find many profitable waves to ride! 🌊✨
Please test, and take into account that it depends on taking multiple longs within the swing, and you only get to invest 25/30% of your equity.
Multi-MA Strategy Analyzer with BacktestMulti-MA Strategy Analyzer with Backtest
This TradingView Pine Script indicator is designed to analyze multiple moving averages (SMA or EMA) dynamically and identify the most profitable one based on historical performance.
Features
Dynamic MA Range:
Specify a minLength, maxLength, and step size.
Automatically calculates up to 20 MAs.
Custom MA Calculation:
Uses custom SMA and EMA implementations to support dynamic length values.
Buy/Sell Logic:
Buy when price crosses above a MA.
Sell when price crosses below.
Supports both long and short trades.
Performance Tracking:
Tracks PnL, number of trades, win rate, average profit, and drawdown.
Maintains individual stats for each MA.
Best MA Detection:
Automatically highlights the best-performing MA.
Optional showBestOnly toggle to focus only on the best line and its stats.
Visualization:
Up to 20 plot() calls (static) for MAs.
Green highlight for the best MA.
Color-coded result table and chart.
Table View
When showBestOnly = false, the table displays all MAs with stats.
When showBestOnly = true, the table displays only the best MA with a summary row.
Includes:
Best MA length
Total PnL
Number of trades
Win rate
Avg PnL per trade
Max Drawdown
Configuration
minLength (default: 10)
maxLength (default: 200)
step (default: 10)
useEMA: Toggle between EMA and SMA
showBestOnly: Focus on best-performing MA only
Notes
MA plotting is static, limited to 20 total.
Table supports highlighting and is optimized for performance.
Script is structured to run efficiently using arrays and simple int where required.
Potential Extensions
Add visual buy/sell arrows
Export stats to CSV
Strategy tester conversion
Custom date range filtering for backtesting
Author: Muhammad Wasim
Version: 1.0
CPR Trading Strategy//@version=5
strategy("CPR Trading Strategy", overlay=true, margin_long=100, margin_short=100)
// Input Parameters
stopLossPerc = input.float(1.5, "Stop Loss %", minval=0.1, maxval=10, step=0.1) / 100
takeProfitPerc = input.float(3.0, "Take Profit %", minval=0.1, maxval=10, step=0.1) / 100
useCPRFilter = input.bool(true, "Use CPR Filter")
showCPRLines = input.bool(true, "Show CPR Lines")
// Calculate CPR Levels
pivot = (high + low + close) / 3
bc = (high + low) / 2
tc = (pivot - bc) + pivot
// Plot CPR Levels
plot(showCPRLines ? pivot : na, "Pivot", color=color.new(#2962FF, 0), linewidth=2)
plot(showCPRLines ? bc : na, "BC", color=color.new(#FF6D00, 0), linewidth=1)
plot(showCPRLines ? tc : na, "TC", color=color.new(#00C853, 0), linewidth=1)
// Trading Conditions
priceAbovePivot = close > pivot
priceBelowPivot = close < pivot
priceBetweenBC_TC = close > bc and close < tc
// Entry Logic
longCondition = priceAbovePivot and (useCPRFilter ? priceBetweenBC_TC : true)
shortCondition = priceBelowPivot and (useCPRFilter ? priceBetweenBC_TC : true)
// Execute Trades
if (longCondition)
entryPrice = close
strategy.entry("Long", strategy.long)
strategy.exit("Long Exit", "Long", stop=entryPrice * (1 - stopLossPerc), limit=entryPrice * (1 + takeProfitPerc))
if (shortCondition)
entryPrice = close
strategy.entry("Short", strategy.short)
strategy.exit("Short Exit", "Short", stop=entryPrice * (1 + stopLossPerc), limit=entryPrice * (1 - takeProfitPerc))
// Visual Signals
bgcolor(longCondition ? color.new(color.green, 90) : shortCondition ? color.new(color.red, 90) : na)
plotshape(longCondition, "Buy Signal", shape.triangleup, location=location.belowbar, color=color.green, size=size.small)
plotshape(shortCondition, "Sell Signal", shape.triangledown, location=location.abovebar, color=color.red, size=size.small)
Hossa OTF 4-candles"Hossa OTF 4-candles," overlays mini-representations of the higher timeframe candle on your current chart and displays a countdown timer showing how much time remains until that higher timeframe candle closes. Here’s how it works and how you might use it:
How It Works
Multi-Timeframe Display:
The indicator fetches the open, high, low, and close of a higher timeframe candle based on the timeframe you select (for example, 1H, 4H, 8H, 1D, or 1W). It then draws four mini-candles that update as new higher timeframe candles are formed.
Simple Stopwatch Countdown:
It retrieves the open time of the current higher timeframe candle and calculates its full duration (using the timeframe’s minutes converted to milliseconds). The indicator then subtracts the elapsed time from the total duration to show a countdown (formatted in hours and minutes) that tells you how long until the current candle closes.
How to Use It
Multi-Timeframe Analysis:
Use this indicator to see at a glance the status of the higher timeframe candle while you trade on a lower timeframe. For instance, if you're trading on a 5-minute chart but want to see what the 4-hour candle is doing, this indicator places a mini-representation of that 4-hour candle right on your chart.
Time-Based Entries/Exits:
The countdown helps you prepare for potential shifts in market sentiment as the higher timeframe candle closes. For example, if you notice a pattern or reversal setup on your lower timeframe near the end of the higher timeframe candle, it could signal an opportunity to enter or exit a trade.
Confluence with Other Indicators:
Combine this tool with other technical indicators (like RSI, MACD, or moving averages) to build a strategy. For instance, you might wait for a divergence on the lower timeframe as the higher timeframe candle nears its close, which can serve as an extra signal for a potential reversal or breakout.
Example Strategy
Trend Confirmation:
Suppose the 4-hour candle is trending upward. Use the mini-candles and countdown timer to monitor when the current 4-hour candle is about to close.
Entry Signal:
If you see a bullish divergence on your lower timeframe (say, on a 15-minute chart) near the end of the 4-hour candle (as the countdown nears zero), this could signal that the uptrend might continue, suggesting a potential buy signal.
Exit Signal:
Conversely, if you see bearish price action or a breakdown of support as the candle closes, you might consider exiting long positions or even taking a short trade.
Please Share
If you find this indicator useful for your multi-timeframe analysis and timing-based strategies, please consider sharing it with your fellow traders. Sharing helps improve our community's tools and fosters collaboration among traders!
Regime Filter IndicatorRegime Filter – Crypto Market Trend Indicator
📊 Overview
The Regime Filter is a powerful market analysis indicator designed specifically for crypto trading. It helps traders identify whether the market is in a bullish or bearish phase by analyzing key assets in the cryptocurrency market, including Bitcoin (BTC), Bitcoin Dominance (BTC.D), and the Altcoin Market (TOTAL3). The indicator compares these assets against their respective Simple Moving Averages (SMA) to determine the overall market regime, allowing traders to make more informed decisions.
🔍 How It Works
The Regime Filter evaluates three main components to determine the market's sentiment:
1. BTC Dominance (BTC.D) vs. 40 SMA (Medium Timeframe)
The Bitcoin Dominance (BTC.D) is compared to its 40-period SMA on a mid-timeframe (e.g.,
1-hour). If BTC.D is below the 40 SMA, it indicates that altcoins are performing well relative
to Bitcoin, suggesting a bullish altcoin market. If BTC.D is above the 40 SMA, Bitcoin is
gaining dominance, indicating a potential bearish phase for altcoins.
2. TOTAL3 Market Cap vs. 100 SMA (Medium Timeframe)
The TOTAL3 index, which tracks the total market capitalization of all cryptocurrencies except
Bitcoin and Ethereum, is compared to its 100-period SMA. A bullish signal occurs when TOTAL3
is above the 100 SMA, indicating strength in altcoins, while a bearish signal occurs when
TOTAL3 is below the 100 SMA, signaling a potential weakness in the altcoin market.
3. BTC Price vs. 200 SMA (Higher Timeframe)
The current Bitcoin price is compared to its 200-period Simple Moving Average (SMA) on a
higher timeframe (e.g., 4-hour). A bullish signal is given when the BTC price is above the 200
SMA, and a bearish signal when it's below.
🟢 Bullish Market Conditions
The market is considered bullish when:
- BTC Dominance (BTC.D) is below the 40 SMA, suggesting altcoins are gaining momentum.
- TOTAL3 Market Cap is above the 100 SMA, signaling strength in the altcoin market.
- BTC price is above the 200 SMA, indicating an uptrend in Bitcoin.
In these conditions, the background turns green 🟢, and a "Bullish" label is displayed on the chart.
🔴 Bearish Market Conditions
The market is considered bearish when:
- BTC Dominance (BTC.D) is above the 40 SMA, indicating Bitcoin is outperforming altcoins.
- TOTAL3 Market Cap is below the 100 SMA, signaling weakness in altcoins.
- BTC price is below the 200 SMA, indicating a downtrend in Bitcoin.
In these conditions, the background turns red 🔴, and a "Bearish" label appears on the chart.
⚙ Customization Options
- The Regime Filter offers flexibility for traders:
- Enable or Disable Specific SMAs: Customize the indicator by enabling or disabling the 200 SMA for Bitcoin, the 40 SMA for BTC Dominance, and the 100 SMA for TOTAL3.
- Adjust Timeframes: Choose the timeframes for each of the moving averages to suit your preferred trading strategy.
- Real-Time Data Adjustments: The indicator updates in real-time to reflect current market conditions, ensuring timely analysis.
📈 Best Use Cases
- Trend Confirmation: The Regime Filter is ideal for confirming the market's overall trend,
helping traders to align their positions with the dominant market sentiment.
- Trade Entry/Exit Signals: Use the indicator to identify favorable entry or exit points based on
whether the market is in a bullish or bearish phase.
- Market Overview: Gain a quick understanding of the broader crypto market, with a focus on
Bitcoin and altcoins, to make more strategic decisions.
⚠️ Important Notes
Trend-Following Indicator: The Regime Filter is a trend-following tool, meaning it works best in strong trending markets. It may not perform well in choppy, sideways markets.
Risk Management: This indicator is designed to assist in identifying market trends, but it does not guarantee profits. Always apply sound risk management strategies and use additional indicators when making trading decisions.
Not a Profit Guarantee: While this indicator can help identify potential market trends, no trading tool or strategy guarantees profits. Please trade responsibly and ensure that your decisions are based on comprehensive analysis and risk tolerance.