ICT FVG [TheFundedRoad]This indicator shows you all ICT Fair value gaps on chart with midpoint line
Fair value gap is a gap in a set of 3 candles, in a bullish FVG you have 1st candle high being lower than third candle low, and in a bearish FVG you have first candle low higher than third candle high, thats how this indicator finds these fair value gaps
It draws the fair value gap from the 2nd candle forward
You can customize the color and if you want to see the midpoint or not, midpoint is 50% of the gap
圖表形態
Pairs trading[Maxxxz7]Pairs Trading
This script is designed to analyze and visualize the divergence or convergence of two selected financial instruments, making it an excellent tool for implementing a pairs trading strategy. Developed for the TradingView platform, it offers extensive customization options for analysis.
Key Features:
Asset Selection:
The first asset can be taken directly from the chart or specified manually.
The second asset is always selected manually.
Data Normalization:
Calculates the percentage change of both assets relative to their initial prices.
Includes an offset for better visual interpretation.
Visualization:
Plots normalized price charts for both assets.
Highlights crossovers between the assets.
Displays the spread (difference between normalized prices) graphically.
Alerts (Works only on the 30-minute timeframe):
Configurable thresholds to trigger alerts (e.g., when the difference is smaller or larger than a set value).
Alerts for crossovers of prices and exponential moving averages (EMA).
Dynamic Labels:
Automatically adds labels to mark key events: crossovers, critical spread values, and current price information.
EMA and Deviation Analysis:
Calculates EMA for each asset.
Alerts for EMA crossovers.
Relative Vigor Index Z-ScoreThe Relative Vigor Index with Z-Score (RVIZ) is a combined technical analysis tool that helps traders assess the strength and volatility of price movements relative to a market's recent price behavior. This indicator incorporates two distinct concepts:
Relative Vigor Index (RVI):
The RVI is a momentum indicator that measures the strength of a trend by comparing the current price range (high vs low) with the opening and closing prices. The RVI is primarily used to determine if the current price movement is "vigorous" (strong) or weak, and it is plotted as a line that oscillates around a zero baseline.
Z-Score:
The Z-score is a statistical measurement that shows how many standard deviations the RVI is from its historical mean over a given period. This helps identify if the current RVI value is unusually high or low relative to past values, providing a normalized view of the indicator's extremity.
The combination of the RVI and Z-Score offers a more nuanced view of market momentum and volatility, allowing traders to assess both the strength of the current trend and its statistical significance.
Inputs:
Length (RVI Length):
The number of bars used to calculate the Relative Vigor Index. A larger length (e.g., 20 or more) results in a smoother RVI, while a shorter length makes the RVI more sensitive to short-term price changes.
Z-Score Length:
The number of bars used to compute the mean and standard deviation of the RVI for the Z-score calculation. This length determines how "historically" the Z-score will assess the RVI's behavior.
Offset:
Allows users to shift the indicator plot to the left or right for visual adjustment, particularly useful in certain charting setups.
Beta CoefficientThe Beta indicator is a technical analysis tool designed to calculate and display the beta coefficient of a specific instrument relative to a chosen benchmark. Beta is a measure of the volatility or systematic risk of an asset compared to the overall market (or a specific benchmark). This indicator helps traders and investors understand how much the price of the instrument moves relative to the benchmark, which is useful for assessing market risk exposure.
Input Parameters:
Beta Measurement Period (length1) :
This parameter defines the look back period for calculating beta, which is typically the number of days (or bars) over which the beta coefficient is computed. The longer the period, the more reliable the measurement of beta will be, as it averages out short-term fluctuations. The default value is 200, but this can be adjusted by the user.
Benchmark Instrument :
The default benchmark in this indicator is the Bitcoin (BTC/USD) index, though this can be adjusted to any other market or asset (e.g., S&P 500, Dow Jones) by modifying the symbol in the script.
Interpretation:
A Beta > 1: The instrument is more volatile than the benchmark. If the benchmark increases or decreases, the instrument is likely to experience larger price movements in the same direction.
A Beta < 1: The instrument is less volatile than the benchmark, meaning its price movements will be smaller relative to the benchmark's changes.
A Beta = 1: The instrument moves in close correlation with the benchmark.
Usage:
This indicator is particularly useful for:
Portfolio Risk Management :
By understanding an asset's beta, traders and investors can assess how much exposure they have to the risk associated with the benchmark.
Market Timing :
The beta coefficient can signal the level of market sensitivity of an asset, which is useful for determining when to take more or less aggressive positions.
Wick Length Display + Alert conditionsDescription of the Wick Length Display (Advanced) script
Originality and purpose of the script
The Wick Length Display (Advanced) script is an innovative tool for traders who want to gain detailed insights into the length of candle wicks. It stands out for its versatility and user-friendly customization options. It combines precise technical calculations with visual representation to provide important information about market movements and dynamics right on the chart.
Functionality
The script calculates and displays the length of the upper and lower wicks of each candle on the chart. It also provides additional visual cues such as:
• “Bull pressure”: When green candles do not have upper wicks, this indicates strong buying pressure.
• “Bear pressure”: When red candles do not have lower wicks, this indicates strong selling pressure.
• Threshold conditions: Only displays wicks that exceed a certain threshold (optional).
• Display in pips: Allows you to display wick lengths in pips, which is useful for forex traders.
How it works
The script analyzes each candle using the following calculations:
1. Wick length calculation:
◦ Upper wick length = High - (top of the body)
◦ Lower wick length = (bottom of the body) - Low
2. Display conditions:
◦ It distinguishes between bullish and bearish candles.
◦ It checks if the calculated wicks exceed the defined thresholds before displaying them.
3. Dynamic labels:
◦ Labels are placed above or below the respective candles.
◦ Size, color and type of labels are fully customizable.
4. Limitation of labels:
◦ To ensure clarity, a maximum number of labels is defined.
Usage
1. Customization:
◦ Open the script in the Pine Script Editor in TradingView.
◦ Use the input options to customize parameters such as color selection, label size, thresholds and other details according to your requirements.
2. Enable thresholds:
◦ Enable thresholds to show labels only for relevant wicks (default is 6).
◦ Define the minimum wick lengths for bullish (green) and bearish (red) candles.
3. Show in pips:
◦ Enable the “Show wick length in pips” option to show the results in pips (especially suitable for Forex).
4. Edit pressure labels:
◦ Turn the “Bull Pressure” and “Bear Pressure” features on or off depending on your analysis settings.
Concepts behind the calculations
• Technical market analysis: Wick lengths can indicate buying or selling pressure and provide important information on market psychology.
• Thresholds and filtering: The script uses thresholds to avoid visual overload and highlight only essential data.
• Label display: Dynamic labels improve chart readability and give the user instant feedback on market developments.
Usage
This script is great for:
• Intraday trading: Analyzing short-term movements using wick lengths.
• Forex trading: Tracking market momentum using the pip indicator.
• Swing trading: Identifying buying or selling pressure in key markets.
• Visual support: Ideal for traders who prefer a graphical display.
Description of the Wick Length Display (Advanced) script
Originality and purpose of the script
The Wick Length Display (Advanced) script is an innovative tool for traders who want to gain detailed insights into the length of candle wicks. It stands out for its versatility and user-friendly customization options. It combines precise technical calculations with visual representation to provide important information about market movements and dynamics right on the chart.
Functionality
The script calculates and displays the length of the upper and lower wicks of each candle on the chart. It also provides additional visual cues such as:
• “Bull pressure”: When green candles do not have upper wicks, this indicates strong buying pressure.
• “Bear pressure”: When red candles do not have lower wicks, this indicates strong selling pressure.
• Threshold conditions: Only displays wicks that exceed a certain threshold (optional).
• Display in pips: Allows you to display wick lengths in pips, which is useful for forex traders.
How it works
The script analyzes each candle using the following calculations:
1. Wick length calculation:
◦ Upper wick length = High - (top of the body)
◦ Lower wick length = (bottom of the body) - Low
2. Display conditions:
◦ It distinguishes between bullish and bearish candles.
◦ It checks if the calculated wicks exceed the defined thresholds before displaying them.
3. Dynamic labels:
◦ Labels are placed above or below the respective candles.
◦ Size, color and type of labels are fully customizable.
4. Limitation of labels
Alert conditions:
Alerts are triggered when the wick length of a bullish or bearish candle exceeds the defined thresholds.
Alert function:
alert() is used to issue messages with a frequency of once per candle when the conditions are met.
How to set up alerts
Save the script and add it to your chart.
Open the alert settings in TradingView.
Select the script's custom message as a trigger.
Adjust the frequency and notification type (popup, email, etc.).
Now you have a powerful tool with visual analysis and alert function!
New Bar AlertThis is probably the simplest indicator on Tradingview, it generates an alert on every new bar.
Useful for strategies where you only need chart attention at the new bar, see if you have a setup.
Helps not having to stare at the charts, the alert will tell you when it's time to take a look.
Works on all timeframes but in order to keep your sanity, best used on higher timeframes, 5mins and up.
Trend, Chart Patterns & Market Structure Indicator [TradeDots]The "Trend, Chart Patterns & Market Structure Indicator" is engineered to identify pivotal price action points, revealing shifts in market dynamics. This tool aids traders to simplify any trading market in recognizing significant price levels, enhancing decision-making in diverse market conditions.
📝 HOW IT WORKS
Pivot Identification
The indicator detects pivots in price action using a complex mathematical model by analyzing a window of candlesticks to capture significant reversal patterns. It examines a series of bars, focusing on their open, high, low, close, and changes in these values, to pinpoint potential market turning points.
Support and Resistance Lines
Calculation: Automatically draws lines at key price pivots in bullish and bearish markets.
Significance: Aligning support and resistance levels highlights strong demand or supply zones, reinforcing trading biases. When multiple lines converge near a price level, it indicates robust support or resistance, as many traders focus on these levels for placing trades.
Chart Patterns Analysis
Formation: Utilizes four pivots to identify patterns such as ascending/descending channels, contraction, and expansion patterns.
Visualization: Background colors (green for bullish, red for bearish) help identify market trends.
Market Structure Shifts
Detection: Identifies price breakouts above or below previous support and resistance, indicating changes in market structure.
Confirmation: Highlights shifts in market character, aiding in trend reversal anticipation.
Types of Market Structure Shifts
Channel Breakout: The price breaks out from the current channel's resistance level.
Rev. Breakout: The price breaks out from a contraction pattern, moving in the opposite direction of the previous market trend.
Continuation Breakout: The price breaks out from a contraction pattern, continuing the previous market trend.
Change of Character (ChoCh): The price breaks out from either support or resistance, causing a change in the market trend.
🛠️ HOW TO USE
Chart Visualization
Color Coding: Background colors signify market trends, with green indicating bullish and red indicating bearish conditions.
Pattern Recognition: Identifies and labels patterns, providing insights into current market sentiment.
Reversal Signals
Signal Labels: Detects shifts in market structure indicating potential entry and exit points.
❗️LIMITATIONS
Market Noise: Accuracy may decrease in volatile and noisy markets.
Trend Confirmation Delay: Market trends are only confirmed once the price breaks out from support or resistance, potentially causing delays.
RISK DISCLAIMER
Trading involves substantial risk, and most traders may incur losses. All content, tools, scripts, articles, and education provided by TradeDots are for informational and educational purposes only.
ImbalancesThis Pine Script is a trading indicator designed to identify imbalances in the market, specifically on candlestick charts. An imbalance refers to situations where there is a significant difference between buyers and sellers, which can create gaps or areas of inefficiency in the price. These imbalances often act as zones where price may return to "fill" or correct these inefficiencies.
1. Identifying Imbalances
The script analyzes candlestick patterns to detect imbalances based on the relationship between the highs, lows, and closes of consecutive candles. Specifically, it looks for:
Top Imbalances (Bearish): Areas where selling pressure has dominated, causing inefficiencies in the price. These are represented by patterns like multiple consecutive bearish candles or bearish gaps.
Bottom Imbalances (Bullish): Areas where buying pressure has dominated, leading to bullish gaps or inefficiencies.
When an imbalance is detected, the script highlights the area using visual boxes on the chart.
2. Visual Representation
The indicator uses colored boxes to show imbalances directly on the chart:
Top (Bearish) Imbalances: Highlighted using shades of red.
Bottom (Bullish) Imbalances: Highlighted using shades of green.
The boxes are further categorized into three states based on their level of mitigation:
Unmitigated: The imbalance has not been "filled" by price yet.
Partially Mitigated: Price has entered the imbalance zone but not completely filled it.
Fully Mitigated: Price has completely filled the imbalance zone.
3. Mitigation Logic
The concept of mitigation refers to the price revisiting an imbalance zone to correct the inefficiency:
If price fully or partially revisits an imbalance zone, the box's color changes to indicate the mitigation level (e.g., from unmitigated to partially/fully mitigated).
Fully mitigated boxes may be removed or recolored, depending on user preferences.
4. User Customization
The script provides several inputs to customize its behavior:
Enable or disable top and bottom imbalance detection.
Color settings: Users can define different colors for unmitigated, partially mitigated, and fully mitigated imbalances.
Mitigation display options: Users can choose whether to show fully mitigated imbalances on the chart or remove them.
5. Key Calculations
Imbalance Size: The size of the imbalance is calculated as the price difference between a candle's high and low across the relevant pattern.
Pattern Detection: The script checks for specific candlestick patterns (e.g., three consecutive bearish candles) to identify potential imbalances.
6. Practical Use Case
This indicator is useful for traders who:
Rely on supply and demand zones for their trading strategies.
Look for areas where price is likely to return (retesting unmitigated imbalances can signal potential trade setups).
Want to visually track market inefficiencies over time.
In Summary
The "Imbalances" indicator highlights and tracks price inefficiencies on candlestick charts. It marks zones where buying or selling pressure was dominant, and it dynamically updates these zones based on price action to indicate their mitigation status. This tool is particularly helpful for traders who use price action and market structure in their strategies.
Perfect Hammer Pattern Indicators and Alerts# Perfect Hammer Pattern Indicators and Alerts
This indicator identifies a specific and precise hammer candlestick pattern formation that can signal potential trend reversals or continuation setups. Unlike traditional hammer pattern indicators, this script focuses on exact wick measurements to identify high-probability trade setups.
## Pattern Specifications
### Bullish Setup Requirements
- Two consecutive green (bullish) candles
- Both candles must have NO lower wick (perfect bottom)
- Both candles must have an upper wick (showing buying pressure)
- Previous candle must be red (bearish) for context
- Marked with a green 'H' below the pattern
### Bearish Setup Requirements
- Two consecutive red (bearish) candles
- Both candles must have NO upper wick (perfect top)
- Both candles must have a lower wick (showing selling pressure)
- Previous candle must be green (bullish) for context
- Marked with a red 'H' above the pattern
## Trading Logic
This pattern is particularly effective because it shows clear control by either buyers (bullish pattern) or sellers (bearish pattern):
- In the bullish pattern, the absence of lower wicks indicates strong buying pressure preventing prices from falling below the open, while the upper wicks show profit-taking at highs
- In the bearish pattern, the absence of upper wicks shows strong selling pressure capping any upward movement, while the lower wicks indicate some buying support below
## Alerts
The indicator includes two alert conditions:
1. Bullish Pattern Alert: Triggers when two perfect bullish hammers appear after a bearish candle
2. Bearish Pattern Alert: Triggers when two perfect bearish hammers appear after a bullish candle
## Usage Tips
- Best used on timeframes 15 minutes and above
- Consider using in conjunction with key support/resistance levels
- Volume confirmation can increase pattern reliability
- The pattern may signal either trend continuation or reversal - always consider the larger market context
## Notes
- This indicator focuses on precise hammer formations rather than approximate patterns
- The requirement for consecutive perfect hammers makes this a relatively rare but high-probability setup
- Visual markers ('H') provide easy pattern identification on charts
SMC Market Structure [BlueCaptial]This indicator is tailored for traders using Smart Money Concepts (SMC) and focuses on identifying:
Trend continuation or reversal points.
High-probability trade zones based on demand and supply.
Liquidity sweeps and their implications for potential price moves.
Key Features:
Market Structure Analysis:
1. Highs and Lows (H/L):
Marks significant highs (H) and lows (L) in the price chart.
Option to display equal highs/lows for pullback and minor structure analysis.
Displays sweeping lines for H/L levels to highlight liquidity grabs (stop hunts).
2. Break of Structure (BoS) and Change of Character (ChoCh):
Detects and labels critical moments in market structure shifts:
BoS: Indicates a break of previous highs/lows, showing potential trend continuation.
ChoCh: Marks potential trend reversals.
Visualized with labels and dashed lines.
3. Internal Structure:
Tracks minor internal movements in the market.
Highlights internal highs (puUp) and lows (puDn) with arrows.
Support for IDM Levels:
IDM (Intermediate Demand and Supply Levels):
Identifies and displays the most recent levels of demand (low) and supply (high).
Option to display both historical and live IDM levels.
Provides visual cues with dotted lines and markers.
Liquidity Sweeps and Key Levels:
Marks liquidity sweeps when significant H/L levels are breached but fail to close beyond
them.
Displays "$$$" markers at these points, signifying areas where stop-loss orders might have
been triggered.
Bar Coloring:
Option to color bars based on specific conditions:
Bullish or Bearish SCOB (Strong Candlestick Breakout):
Bullish SCOB: Price breaks above previous highs with strength.
Bearish SCOB: Price breaks below previous lows with strength.
Custom bar coloring based on trends (bullish or bearish).
Configurable Inputs:
H/L Marking Options:
Enable/disable H/L markers, and set their colors.
BoS/ChoCh :
Configure labels, colors, and visibility for BoS and ChoCh markers.
Internal Structure:
Customize colors for minor highs (puUp) and lows (puDn).
Sweeps:
Toggle sweeping line display and configure colors.
IDM Levels:
Display live and historical IDM levels with customizable styles.
Structure Pilot - Z&Z [Wang Indicators]Structure Pilot Zone & Zil is a complete suite of structure driven features that's build around pattern that can be visible around any timeframe.
Built in collaboration with Dave Teaches,
All these tools were shaped and combined together as the only toolkit Structure & DTFX traders want to have !
▫️ Structures & Zones ▫️
Zones are drawn when a break of structure (new high or low being created) or a market reversal happens.
It will highlight the last valid down move before a new high for bullish zones and the last valid up move before a new low for bearish zones.
These zones are used to analyze the market trend and to make entries into the market trend once the price retraces into these zones.
For example, with the latest bullish zones drawn in green for LTF zones and in blue for HTF zones, when the price retraces into this zone, there is a strong probability that the price will turn around to provide a buying opportunity all the way to the top of the zone or even higher.
These buying opportunities generally occur at specific retracement levels in the 30%, 50% and 70% zones, automatically represented by broken lines in the zones when they are created.
Example with bullish zones :
The aim with these zones is to find places on the chart where it's best to buy or sell, in order to take the biggest possible move while minimizing your risk.
Indeed, if the price is rising and a bullish zone has been created, I don't want to buy on the highs, preferring to wait for a retracement in my bullish zone to buy lower and reduce my risk, as the invalidation of the current trend will be found below the last protected low under the bullish zone drawn in blue for the HTF and in green for the LTF. Conversely, if the price is falling and a bearish zone has been created, I don't want to sell at the bottom. I'd rather wait for a retracement in the bearish zone to sell higher and reduce my risk, as the invalidation of the current trend will this time be above the last protected high above the bearish zone drawn in orange for the HTF and red for the LTF.
Example with bearish zones :
When it comes to market structure, it's good to know that zones recur within the same trend at a frequency of between 3 and 6 before there's a trend reversal.
So, after a certain number of successive zones, you can expect a reversal or the last protected high or low to be breached. The indicator automatically counts the number of successive zones, so you can keep track of the market and avoid surprises.
The zones are generated through the structure length. It can be increased to display larger (and more important) zones.
As we recommend keeping the default value (20) for new traders, experienced traders will find some success with other settings depending on their strategies.
Structure Pilot also provides auto HTF Zones, which is particularly useful to have a macro vision of the market.
Settings:
Swing types: Bullish only, Bearish only, both, or none
Structure length
Swing count: useful when it comes to tracking Trend strenght in any given time frame
Show Zones: Display boxes with 30%, 50%, and 70% fibs
Show HTF Zones: Display HTF zones with the same retracement configuration as the regular zones
Show 30%, 50% and 70%: Enable/disable these options to show or hide the corresponding fibs.
Box visibility, Line width & Line style: Style configuration for the zone
All settings can be activated or deactivated in the indicator parameters to suit individual needs and preferences.
30% Level : This is often considered a shallow retracement. If prices pull back to this level after an uptrend and flip in a lower timeframe, traders might view it as a strong sign of continued bullish momentum. Conversely, after a downtrend, this level could act as a temporary resistance where sellers might re-enter after a flip in a lower timeframe.
50% Level : This level is seen as a balance point or midpoint in the price move. A retracement to 50% can indicate a strong trend change or continuation.
70% Level : A retracement this deep can signal that the market might be losing steam or that the previous trend could be weakening. If the price bounces off this level, it might suggest that the trend is still in control but needed a more significant correction before moving further in its original direction.
We as structure traders prefer to take entry out of The 50% or when price retrace past it
there will be something at the level i'm looking for price to reverse from either some specific candles or imbalances.
Advanced traders might combine these levels with other tools or chart patterns that we bundle in this indicator.
▫️ ZIL ▫️
The ZIL Indicator is designed to automate the process of identifying key structural levels in the market and applying Fibonacci retracements when a significant price break occurs.
The indicator detects when a market structure (high or low) is broken and a candle closes below the previous low or above the previous high, indicating a potential trend shift or continuation.
• Tracks the break of structural lows or highs and waits for a confirmation candle that closes above or bellow the candle that set the new low.
Automated Fibonacci Retracement:
• Once the structure break is confirmed, the indicator automatically plots a Fibonacci retracement between:
• The high of the last bullish move (before the new low is set) or the low of the last bearish move (before the new high is set)
• The newly formed low after the structure break or the newly formed high after the structure break
Fibonacci levels plotted with colors :
• -0.27 : Dark red - Stop loss
• 0 : white - The new high/low - Potential entry
• 0.3, Orange 0.5, Light green 0.7: Green : Levels - Partial and take profit zones
• 1.15 pale blue - for your runner
We may long the retracement when the price is comming from a bearish zone using the ZIL to manage
Example :
Multi-Timeframe Support:
• Using the option "HTF ZIL" will display ZIL on higher timeframe (corresponding to the HTF Zones) on your charts to help traders find structural breaks and Fibonacci setups in both short-term and long-term markets.
HTF ZIL is really usefull to manage trades if the regular ZIL target get ran through
Wang use case :
HTF zill level are used when the small zill get ran through
▫️ Opening Range Tracker ▫️
The Opening Range Tracker is designed to help traders identify and track the opening range of a specified time period, specifically starting with the 144-minute candle between 8:24 AM and 10:48 AM. (default value) The indicator highlights this range and automatically plots key levels (30%, 50%, 70%) to provide potential strong reaction areas for trading. The time period for the opening range is fully customizable, allowing users to adjust it according to their strategy.
Opening range should be seen and used as a classic zone. If we trade above or below it price tend to come back into it and bounce of of the One or multiple level...
classic 30/50/70.
• Customizable Opening Range: Adapt the indicator to any market or session by changing the opening range time window.
• Precise Levels for Trading: The 30%, 50%, and 70% levels provide key zones where price may react, helping traders define entries, exits, or stop loss placements.
• Visual Clarity: The range box and levels make it easy to see the important price areas during the opening range and the rest of the trading session. If we range a lot in the opening range, we may range for the rest of the day. We should keep that in mind to avoid taking wrong decisions.
its basically a large zone that's we have seen often time price rejects from the level in it
Daily Reset: Each trading day resets the opening range, giving traders fresh data and new opportunities to capitalize on market movements.
Structure Pilot is built for beginner and experienced. It provides the tools to the traders that want to learn, understand, and trade efficiently within the principles of structure trading.
Moving Average with Buy/Sell SignalsBINANCE:BTCUSD
Pine Script Brief: "44 Moving Average with Buy/Sell Signals"
This Pine Script is designed to generate buy and sell signals based on the interaction of the price with the 44-period Simple Moving Average (SMA). It also considers the closing behavior of the last five candles to further refine the conditions for generating signals. The script is intended for use in technical analysis for trading strategies on platforms like TradingView.
Features:
44-Period Simple Moving Average (SMA):
The script calculates and plots the 44-period SMA of the closing price on the chart, providing a trend-following indicator.
The SMA is used as a key level to determine when price action is "touching" or interacting with the moving average.
Buy and Sell Signal Logic:
Buy Signal:
The candle is green (close > open).
The candle's high and low are around the 44 SMA, indicating the candle is "touching" or near the moving average.
At least 2 of the last 5 candles must have closed above the 44 SMA.
The 44 SMA is positioned below the midpoint of the current candle.
Sell Signal:
The candle is red (close < open).
The candle's high and low are around the 44 SMA.
At least 2 of the last 5 candles must have closed below the 44 SMA.
The 44 SMA is positioned above the midpoint of the current candle.
Label Plotting:
The script uses the plotSignal function to plot buy and sell labels directly on the chart. The labels are plotted at the low of a green candle (for buy signals) and the high of a red candle (for sell signals).
Labels are color-coded for quick identification: green for buy and red for sell.
EMA for Smoothing (Optional):
An optional Exponential Moving Average (EMA) is plotted for additional trend smoothing, allowing users to visualize another moving average for possible trend-following strategies.
The length of the EMA is customizable, and it is plotted on the chart alongside the 44 SMA.
Alert Conditions:
Alerts can be set up for both buy and sell signals, notifying the user when these conditions are met. The alerts are triggered whenever the script detects a valid buy or sell signal.
Customizable Inputs:
The script allows customization of the following:
Smoothing Length: For the optional EMA line.
Tolerance: For adjusting the proximity check (candle touching the 44 SMA).
Styling: The color and text of the buy and sell labels can be customized.
Usage:
This script can be used by traders who want to identify possible entry and exit points based on price interaction with the 44-period moving average, combined with the behavior of previous candles. It is suitable for trend-following strategies and can be used in conjunction with other indicators to refine trading decisions.
Key Benefits:
Provides visual signals (buy/sell) directly on the chart.
Considers both immediate price action and historical trends (previous candles).
Offers customization for moving averages and labels.
Alerts can be set for automated notifications.
This Pine Script helps traders make informed decisions by combining the reliability of moving averages with price action and historical candle behavior, enhancing trading strategies based on trend-following principles.
Asset MaxGain MinLoss Tracker [CHE]Asset MaxGain MinLoss Tracker – Your Tool to Discover the Best Trading Opportunities
Introduction
Hello dear traders,
Today, I'd like to introduce you to a fantastic tool: the Asset MaxGain MinLoss Tracker . This indicator is designed to help you identify the best trading opportunities in the market by analyzing the maximum gain and adjusted maximum loss potentials of various assets.
Why Use This Indicator?
1. Time-Saving Analysis
Instead of spending hours sifting through different charts, this indicator provides you with key metrics for up to 10 assets at a glance.
2. Compare Multiple Assets Simultaneously
Monitor and compare multiple assets to discover which ones offer the highest profit potential and the lowest risk of loss.
3. Customizable Settings
Adjust the observation period and select the assets you want to analyze according to your trading strategy.
4. Clear Visual Representation
Data is presented in an easy-to-read table directly on your chart, highlighting assets with the highest maximum gain and the lowest adjusted maximum loss.
How to Use It in Everyday Trading
Step 1: Setting Up the Indicator
Select Your Assets: Choose up to 10 assets you wish to track. These can be cryptocurrencies, stocks, forex pairs, etc.
Configure the Trading Period Length: Set the number of bars (candles) over which you want to calculate the maximum gain and adjusted maximum loss. This allows you to tailor the analysis to your preferred time frame, whether it's short-term trading or long-term investing.
Step 2: Interpreting the Results
Maximum Gain (%): This value shows the potential upside of each asset over the selected period. A higher percentage indicates a greater potential for profit if the asset's price moves upward.
Adjusted Maximum Loss (%): This figure represents the potential downside risk, adjusted to give a more accurate reflection of loss potential. A lower percentage means less risk of significant loss.
Category Highlighting: Assets are categorized based on their performance:
High Gain & Low Loss: Assets that have both the highest max gain and the lowest adjusted max loss.
High Gain: Assets with the highest max gain.
Low Loss: Assets with the lowest adjusted max loss.
Step 3: Making Trading Decisions
Identify Opportunities: Focus on assets categorized as High Gain & Low Loss for the most favorable risk-to-reward scenarios.
Risk Management: Use the adjusted maximum loss to assess and mitigate potential risks associated with each asset.
Portfolio Diversification: Allocate your investments across assets with varying levels of gain and loss potentials to diversify your portfolio effectively.
Practical Example
Imagine you're monitoring the following assets:
Asset 1: BTCUSD
Asset 2: ETHUSD
Asset 3: ADAUSD
Asset 4: XRPUSD
After applying the indicator:
BTCUSD shows a high maximum gain but also a high adjusted maximum loss.
ETHUSD has both a high maximum gain and a low adjusted maximum loss, categorizing it as High Gain & Low Loss.
ADAUSD indicates a low maximum gain but the lowest adjusted maximum loss.
XRPUSD reflects moderate values in both categories.
Decision Making:
Primary Focus: ETHUSD may be your top choice due to its high reward and lower risk.
Risk-Averse Option: ADAUSD could be considered if you prioritize minimizing losses.
Balanced Approach: Diversify by investing in both ETHUSD and ADAUSD.
Understanding the Core Functionality
While you don't need to delve deep into the code to use the indicator effectively, understanding its core function can enhance your confidence in the tool.
The Main Function: Calculating Max Gain and Adjusted Max Loss
The heart of the indicator is a function that calculates two critical metrics for each asset:
Maximum Gain (sym_MaxGain):
Purpose: Measures the highest potential profit over the selected period.
How It Works: It finds the lowest price (sym_minlow) within the period and calculates the percentage increase to the current high price. This shows how much you could have gained if you bought at the lowest point.
Adjusted Maximum Loss (sym_AdjustedMaxLoss):
Purpose: Provides an adjusted measure of the potential loss, giving a more realistic risk assessment.
How It Works: It identifies the highest price (sym_maxhigh) within the period and calculates the percentage decrease to the current low price. This value is adjusted to account for the diminishing impact as losses approach 100%.
Simplified Explanation of the Function
Data Retrieval: For each asset (sym), the function retrieves the high and low prices over the specified timeframe.
Calculations:
Find Highest and Lowest Prices: Determines sym_maxhigh and sym_minlow within the tracking period.
Compute Max Gain: Calculates the potential gain from sym_minlow to the current high.
Compute Max Loss: Calculates the potential loss from sym_maxhigh to the current low.
Adjust Max Loss: Adjusts the max loss calculation to prevent distortion as losses near 100%.
Output: Returns both sym_MaxGain and sym_AdjustedMaxLoss for further analysis.
Benefits of Understanding the Function
Transparency: Knowing how these values are calculated can increase your trust in the indicator's outputs.
Customization: If you're familiar with coding, you might tailor the function to suit specific trading strategies.
Enhanced Analysis: Understanding the underlying calculations allows you to interpret the results more effectively, aiding in better decision-making.
Conclusion
The Asset MaxGain MinLoss Tracker is a powerful tool that can significantly enhance your trading efficiency and effectiveness by:
Providing Quick Insights: Save time by getting immediate access to essential performance metrics of multiple assets.
Assisting in Risk Management: Use the adjusted maximum loss to understand and mitigate potential risks.
Supporting Strategic Decisions: Identify assets with the best risk-to-reward ratios to optimize your trading strategy.
Take advantage of this indicator to elevate your trading game and make more informed decisions with confidence.
Thank you for your time, and happy trading!
Disclaimer:
The content provided, including all code and materials, is strictly for educational and informational purposes only. It is not intended as, and should not be interpreted as, financial advice, a recommendation to buy or sell any financial instrument, or an offer of any financial product or service. All strategies, tools, and examples discussed are provided for illustrative purposes to demonstrate coding techniques and the functionality of Pine Script within a trading context.
Any results from strategies or tools provided are hypothetical, and past performance is not indicative of future results. Trading and investing involve high risk, including the potential loss of principal, and may not be suitable for all individuals. Before making any trading decisions, please consult with a qualified financial professional to understand the risks involved.
By using this script, you acknowledge and agree that any trading decisions are made solely at your discretion and risk.
This indicator is inspired by the "Max Gain" indicator. A special thanks to Skipper86 for his relentless effort, creativity, and contributions to the TradingView community, which served as a foundation for this work.
Risk-Reward Labels Minimal with OffsetIndicator Explanation
The indicator “Risk-Reward Labels Minimal with Offset” is designed to assist traders in managing risk and potential rewards. It displays the Stop-Loss (SL) and Take-Profit (TP) levels for both long and short positions based on identified support and resistance levels.
Key Features:
1. Risk-Reward Ratio: Traders can adjust the risk-reward ratio to define the relationship between potential losses and potential gains (e.g., 1:1 or 1:2).
2. Risk Distance: The distance (in pips) is set to determine where to place the SL and TP levels.
3. Labels with Offset: SL and TP labels can be shifted by an offset (bars), allowing for better visualization.
4. Support and Resistance Levels: The indicator dynamically calculates support and resistance. When a support or resistance level is broken, the corresponding labels are deleted.
5. Display in Range Markets: If the market is ranging or lacks a clear trend, both long and short labels are displayed. This allows traders to identify potential entry opportunities in both directions, even when the market is not clearly trending.
6. Deletion Logic: If the price falls below support or rises above resistance, the relevant SL and TP labels are removed. However, in a Range situation, the possibility of seeing both long and short labels remains, increasing flexibility and helping to avoid false signals.
Order BlockOverview:
The Order Block Indicator is designed to help traders identify key bullish and bearish order blocks on their charts. Order blocks are significant price zones where institutional activity may have occurred, often leading to strong reversals or continuations. This indicator visually highlights these blocks and provides alerts for potential trade opportunities.
Key Features
Bullish Order Blocks (Yellow):
Identifies bullish structures where price signals a potential upward movement.
Highlighted in bright yellow to stand out on your chart.
Bearish Order Blocks (Pink):
Detects bearish structures where price suggests a possible downward movement.
Highlighted in pink for easy identification.
Alerts for Order Blocks:
Sends a notification whenever a bullish or bearish order block is detected.
Keeps you informed of key market zones even when you’re away from the screen.
How It Works
Bullish Order Block Criteria
The last candle (close ) is bullish (close > open).
The second last candle (close ) is bearish (close < open).
The bullish candle’s close is above the high of the bearish candle.
The bearish candle’s close is above the low of the third last candle.
The bearish candle’s low is below the low of the third last candle.
The current candle’s low is above the bearish candle’s high.
These conditions combine to identify strong bullish zones.
Bearish Order Block Criteria
The last candle (close ) is bearish (close < open).
The second last candle (close ) is bullish (close > open).
The bearish candle’s close is below the low of the bullish candle.
The third last candle’s high is above the bullish candle’s close.
The bullish candle’s high is above the high of the third last candle.
The current candle’s high is below the bullish candle’s low.
This logic highlights potential bearish zones.
How to Use It
Add the Indicator to Your Chart:
Use it on any timeframe to spot bullish or bearish order blocks.
Visual Assistance:
Yellow bars indicate bullish order blocks.
Pink bars represent bearish order blocks.
Set Alerts:
Configure alerts to notify you when a bullish or bearish order block appears.
Customization
Colors: Easily change the colors for bullish and bearish order blocks.
Alerts: Adjust alert messages to suit your trading preferences.
Disclaimer:
This indicator is a technical analysis tool and should be used alongside other strategies and market analysis. It does not guarantee profits and carries trading risks. Always trade responsibly.
Pivot Length Percentiles### Pivot Length Percentiles — Analyze Pivot Behavior with Precision 🎯
#### Overview
The **Pivot Length Percentiles** indicator is a powerful tool designed to analyze and visualize the distances between pivot highs and lows on your chart. By calculating percentiles, it provides traders with valuable insights into market structure, volatility, and pivot behavior, helping to make informed trading decisions.
#### Key Features
- **Customizable Pivot Lengths:** Adjust the number of bars to the left and right of a pivot to match your trading strategy.
- **Percentile Analysis:** Calculate and display the 50th (low), 85th (mid), and 99th (high) percentiles of the distances between pivots.
- **Real-Time Statistics Table:** View the latest statistics, including:
- Pivot-to-pivot distances
- Current distance from the last pivot
- Last pivot type and price
- **Intuitive Inputs with Tooltips:** Easily configure the indicator with clear descriptions for each input field.
#### How It Works
1. **Pivot Detection:** The script identifies pivot highs and lows based on user-defined parameters (`Left Bars` and `Right Bars`).
2. **Distance Calculations:** The distances between consecutive pivots and the number of bars between them are recorded.
3. **Percentile Computation:** The distances are sorted to calculate specified percentiles (`Low`, `Mid`, `High`), giving a statistical perspective on market movements.
4. **Visualization:** A statistics table at the bottom of the chart displays the calculated values, ensuring quick and easy reference.
#### Use Cases
- **Identify Market Ranges:** Use pivot distances to identify typical price movement ranges in a given market condition.
- **Plan Entries and Exits:** Leverage the percentile calculations to predict potential retracement levels or continuation patterns.
- **Market Structure Analysis:** Study the relationship between pivot distances and market volatility over time.
#### Inputs Explained
- **Left Bars:** Defines how many bars to the left are considered in pivot detection.
- **Right Bars:** Defines how many bars to the right are considered in pivot detection.
- **Low Percentile:** Specifies the lower boundary percentile for pivot distances.
- **Mid Percentile:** Specifies the median percentile for pivot distances.
- **High Percentile:** Specifies the upper boundary percentile for pivot distances.
#### Tips for Use
- Adjust pivot lengths (`Left Bars` and `Right Bars`) to match your desired level of granularity or market timeframe.
#### Final Thoughts
The Pivot Length Percentiles indicator bridges the gap between statistical analysis and trading by providing actionable insights into pivot behavior. Whether you're a scalper, day trader, or swing trader, this tool can help refine your strategy and enhance your market understanding.
28 minutes ago
Prometheus Markov ChainThe Prometheus Markov Chain Indicator is a custom-built tool designed to predict potential future price movements using a Markov Chain approach. A Markov Chain is a statistical model that assumes the probability of moving to a future state depends solely on the current state. In this indicator, states represent price movement classifications—bullish, bearish, or neutral—and are determined based on historical price changes (percentage returns). The indicator builds a transition matrix to calculate probabilities of transitioning from one state to another, enabling traders to identify patterns and forecast likely price actions.
Core Functionality and Transition Matrix
The transition matrix is the backbone of the Markov Chain. It captures the frequency of transitions between states in the historical price data and normalizes these counts into probabilities. For example, if the price was in a bearish state and transitioned to a bullish state 3 out of 10 times, the probability of transitioning from bearish to bullish would be 0.3. The matrix is created dynamically using the stateFunc function to classify states, which can use either dynamic thresholds (highest and lowest returns over a lookback period) or a user-defined percent return threshold. Below is the snippet that updates the transition matrix:
transitionMatrix = matrix.new(dimension, dimension, 0.0)
for i = 0 to array.size(vec) - 2
fromState = array.get(vec, i)
toState = array.get(vec, i + 1)
transitionMatrix.set(fromState, toState, transitionMatrix.get(fromState, toState) + 1)
for i = 0 to dimension - 1
rowSum = 0.0
for j = 0 to dimension - 1
rowSum += transitionMatrix.get(i, j)
for j = 0 to dimension - 1
prob = transitionMatrix.get(i, j) / rowSum
transitionMatrix.set(i, j, prob)
This snippet iterates through historical price movements, counts state transitions, and then normalizes each row of the matrix so that the sum of probabilities for all possible transitions from a given state equals 1.
How the Indicator Predicts Future States
After constructing the transition matrix, the indicator calculates the current state of the price based on the latest percentage return and then uses the matrix to compute probabilities for transitioning to other states. The state with the highest probability is predicted as the next state, which is displayed on the chart using color-coded labels: green for bullish and red for bearish. The following snippet demonstrates how the current state and predictions are calculated:
current_chng = (close - close ) / close
var int current_state = na
if not use_custom_thresh
highest_chng = ta.highest(current_chng, int(size) * 2)
lowest_chng = ta.lowest(current_chng, int(size) * 2)
current_state := stateFunc(current_chng, highest_chng, lowest_chng)
else
current_state := stateFunc(current_chng, custom_thresh)
predicted_probs = array.new(dimension, 0.0)
for j = 0 to dimension - 1
array.set(predicted_probs, j, transitionMatrix.get(current_state, j))
The indicator evaluates which state has the highest transition probability (highest_prob) and places corresponding labels on the chart. For example, if the next state is predicted to be bullish, a green "Bullish" label is placed below the current bar. This predictive functionality helps traders anticipate potential reversals or continuations in price trends based on historical behavior patterns.
Usage:
Here we see the indicator at work on $PLTR. The states predicted are bullish then bearish. In this example we then see price move in a way that verifies those predictions.
On this 4 Hour NASDAQ:AMZN chart we see predictions play out in a short trade style. States quickly move from one to another but not without giving traders a way to take advantage.
This is the perspective we aim to provide. We encourage traders to not follow indicators blindly. No indicator is 100% accurate. This one can give you a different perspective market state. We encourage any comments about desired updates or criticism!
Crypto Arbitrage Scanner [CryptoSea]Crypto Arbitrage Scanner
The Crypto Arbitrage Scanner is an advanced tool designed to help traders identify arbitrage opportunities across multiple cryptocurrency exchanges. With the ability to compare prices, volumes, and differences in price, this indicator is a must-have for any trader seeking to exploit cross-exchange inefficiencies in real time.
Key Features
Multi-Exchange Price and Volume Comparison: Tracks data from multiple major cryptocurrency exchanges, including BINANCE, COINBASE, KUCOIN, and others, allowing traders to easily compare prices and volume across platforms.
Customizable Difference Metrics: Allows users to toggle between displaying price differences in percentages or absolute dollar values, depending on the preferred metric for arbitrage analysis.
Sorting and Filtering Options: Includes user-defined sorting options to order the data by Price, Volume, or Difference, helping to prioritize potential arbitrage opportunities based on the trader's chosen criteria.
Difference and Volume Thresholds: Users can specify the minimum volume and price difference thresholds, ensuring that only significant arbitrage opportunities are highlighted.
Real-Time Alerts: Built-in alert conditions notify users when arbitrage opportunities exceed their defined price difference thresholds, helping traders respond instantly to market movements.
The Crypto Arb Scanner displays a table of prices, volumes, and price differences across selected exchanges. Each exchange is listed along with the current close price, volume, and the difference in price compared to the average price across all exchanges. Highlighting is used to indicate significant differences that may present arbitrage opportunities.
In the example below, we can see a highlighted opportunity in green showing that the price is below the user inputed thresold.
How it Works
Data Collection: Gathers real-time volume and price data from various exchanges using a streamlined process, allowing for a detailed comparison.
Average Price Calculation: Computes the average price across all valid exchanges to identify where price discrepancies occur, providing a clear picture of arbitrage potential.
Sorting Mechanism: Utilizes custom sorting based on user preferences, making it easy to quickly analyze and identify key opportunities.
Dynamic Highlighting and Alerts: Price differences that exceed user-defined thresholds are highlighted, and alerts can be triggered for these arbitrage opportunities, allowing for a timely response.
Application
Arbitrage Trading: The Crypto Arb Scanner is ideal for traders looking to exploit price differences across exchanges, enabling efficient arbitrage opportunities.
Market Efficiency Analysis: Offers insights into the consistency of prices across exchanges, which can help gauge the efficiency and liquidity of the markets being traded.
Customizable Alerts: Set alerts based on price differences or volume, allowing traders to stay informed about changes without constantly monitoring the markets.
The Crypto Arbitrage Scanner is a powerful addition to any trader's toolkit, offering comprehensive features to detect arbitrage opportunities with confidence. With real-time monitoring, customizable metrics, and a user-friendly interface, this tool allows traders to make informed decisions and capitalize on inefficiencies across exchanges.
Enhanced Kaufman Adaptive Moving Average (KAMA) with Bollinger B# Enhanced Kaufman Adaptive Moving Average (KAMA) with Bollinger Bands
## Overview
This indicator combines the Kaufman Adaptive Moving Average (KAMA) with Bollinger Bands to create a comprehensive trading system. It provides adaptive trend following capabilities while measuring market volatility and potential reversal points.
## Key Features
- Adaptive moving average that adjusts to market conditions
- Dynamic Bollinger Bands for volatility measurement
- Color-coded KAMA line indicating trend direction
- Integrated buy/sell signals based on multiple confirmations
- Customizable parameters for both KAMA and Bollinger Bands
- Optional bar confirmation wait feature
- Built-in alert conditions for trade signals
## Main Components
### 1. Kaufman Adaptive Moving Average (KAMA)
- Adapts to market volatility using an efficiency ratio
- Changes color based on trend direction (green for uptrend, red for downtrend)
- Adjustable parameters for fine-tuning:
- Base Length: Controls the main calculation period (default: 10)
- Fast EMA Length: For rapid market response (default: 2)
- Slow EMA Length: For stable market conditions (default: 30)
### 2. Bollinger Bands
- Standard deviation-based volatility bands
- Customizable length and standard deviation multiplier
- Includes expansion threshold for volatility measurement
- Components:
- Upper Band: Upper volatility threshold
- Middle Band: Simple moving average
- Lower Band: Lower volatility threshold
## Signal Generation
### Buy Signals
Generated when:
1. KAMA color changes from red to green
2. Price closes above KAMA
3. Price closes above the middle Bollinger Band
4. Signals are marked with:
- Green triangles below the candles
- "B" labels for easy identification
### Sell Signals
Generated when:
1. KAMA color changes from green to red
2. Price closes below KAMA
3. Price closes below the middle Bollinger Band
4. Signals are marked with:
- Red triangles above the candles
- "S" labels for easy identification
## Customizable Parameters
### KAMA Settings
- Base Length (1-50)
- Fast EMA Length (1-10)
- Slow EMA Length (10-50)
- Source Price Selection
- Direction Highlight Toggle
- Bar Confirmation Option
### Bollinger Bands Settings
- Length (default: 20)
- Standard Deviation Multiplier (default: 2.0)
- Expansion Threshold (0.1-3.0)
## Alert Functionality
Built-in alerts for:
- Buy signals with customizable messages
- Sell signals with customizable messages
## Best Practices
### Timeframe Selection
- Works well on multiple timeframes
- Recommended for 15m to 4h charts for optimal signal generation
- Higher timeframes provide more reliable trend signals
### Parameter Optimization
- Adjust KAMA lengths based on trading style:
- Shorter lengths for day trading
- Longer lengths for swing trading
- Fine-tune BB multiplier based on market volatility
- Consider waiting for bar confirmation in volatile markets
### Risk Management
- Use in conjunction with other indicators for confirmation
- Consider market conditions and volatility when trading signals
- Implement proper position sizing and stop-loss levels
## Technical Notes
- Written in Pine Script™ v6
- Overlay indicator (displays on price chart)
- Compatible with all TradingView-supported markets
- Resource-efficient implementation for smooth performance
## Disclaimer
This indicator is provided under the Mozilla Public License 2.0. While it can be a valuable tool for technical analysis, it should not be used as the sole basis for trading decisions. Always combine with proper risk management and additional analysis methods.
4-Frame Trend CountThis script tracks the current close vs the close from 4 time frames prior to spot a trend reversal after 9 consecutive up or down moves.
Richs Market StructureThis Pine Script indicator, "Last Bullish High & Lowest Low Tracker with Timeframe Background and Fill", is designed to visually track bullish and bearish trends based on price action on the current chart and a user-defined timeframe. It provides dynamic line plotting, area fills, and background coloring to represent trend alignment between the current chart and the selected timeframe.
Features and Functionalities
Tracks Bullish Highs and Bearish Lows:
The script identifies:
Bullish High: The highest price reached after a bullish (green) candle.
Bearish Low: The lowest price reached after a bearish (red) candle.
It dynamically updates these levels based on the price movements.
Line Plotting:
Current Chart Lines:
The Plotted Bullish High line (green/red) indicates the last bullish high.
The Lowest Low line (green/red) indicates the last bearish low.
Selected Timeframe Lines:
A separate set of lines is plotted for the user-defined timeframe (e.g., daily, weekly):
A Bullish High Line for the selected timeframe (lighter green).
A Lowest Low Line for the selected timeframe (lighter red).
Dynamic Area Fills:
The area between the Plotted Bullish High and Lowest Low is filled:
Green Fill: When both lines are green (indicating a bullish alignment).
Red Fill: When both lines are red (indicating a bearish alignment).
For the selected timeframe:
The area between the timeframe-specific Bullish High and Lowest Low is similarly filled with lighter colors.
Background Color Based on Timeframe Alignment:
The background color represents the trend alignment on the selected timeframe:
Green Background: When the timeframe’s Bullish High is rising and Lowest Low is rising (bullish trend).
Red Background: When the timeframe’s Bullish High is falling and Lowest Low is falling (bearish trend).
What It’s For
This indicator is designed for traders who want to:
Visualize Trends Across Timeframes:
It helps identify when the current chart’s trend aligns with a higher timeframe trend (e.g., daily, weekly).
Useful for multi-timeframe analysis.
Spot Bullish and Bearish Trends:
The color-coded lines and fills clearly show the dominant trend on both the current chart and the selected timeframe.
Plan Trades Based on Trend Alignment:
When the current chart and selected timeframe show the same trend:
Both lines and fills turn green (bullish).
Both lines and fills turn red (bearish).
This alignment is a potential signal for entering long or short trades.
Identify Reversals and Divergences:
Divergence between the current chart and timeframe trends (e.g., green on one, red on the other) may indicate trend weakening or reversal.
Visual Elements
Lines:
Solid lines (current chart): Represent the Plotted Bullish High and Lowest Low.
Dashed/lighter lines (selected timeframe): Represent the timeframe-specific Bullish High and Lowest Low.
Fills:
Green/Red fills highlight trend zones:
On the current chart (darker).
On the selected timeframe (lighter).
Background:
The entire chart background turns green or red based on the selected timeframe’s trend alignment.
Summary
This indicator is ideal for traders who want a clear visual representation of price trends and multi-timeframe alignment. It simplifies trend-following strategies by providing:
Easy-to-interpret fills and background colors.
Clear bullish and bearish zones.
Multi-timeframe trend confirmation.
MichaelSuperTimeFrameMichaelSuperTimeFrame
MichaelSuperTimeFrame is a powerful multi-timeframe tool designed to help traders identify key price levels by dynamically plotting the highest and lowest values for a user-defined timeframe. Whether you’re a scalper, day trader, or swing trader, this indicator simplifies multi-timeframe analysis and enhances your decision-making process by providing clear and actionable insights.
Features:
Customizable Timeframe: Select any timeframe (e.g., hourly, 4-hour, daily) to view high and low levels.
Dynamic Updates: Automatically adjusts to reflect the latest highs and lows for the chosen timeframe.
Clear Visual Markers: Highlights critical support and resistance levels with clean lines and labels.
Multi-Purpose Utility: Suitable for identifying potential breakout levels, stop-loss placements, and price reversals.
How It Works:
Select your desired timeframe in the settings.
The script fetches and plots the high and low prices for the specified timeframe directly on your chart.
Green lines and labels indicate the high levels, while red lines and labels indicate the low levels.
How to Use It:
Trend Analysis: Identify potential breakout zones by observing price interaction with the plotted levels.
Support/Resistance: Use the levels as key support and resistance zones for trade entries or exits.
Stop Placement: Safely place stops above/below key levels based on the timeframe’s context.
Why It's Unique:
MichaelSuperTimeFrame stands out by combining simplicity and flexibility, allowing traders to seamlessly integrate multi-timeframe analysis into their strategies. Its clear visual representation eliminates chart clutter, making it a valuable addition to any trader’s toolkit.
Disclaimer:
This script is designed for educational purposes and is not a trading signal provider. Past performance of any method or indicator is not indicative of future results. Always perform your own analysis before making trading decisions.
Breaks and Retests - Free990Strategy Description: "Breaks and Retests - Free990"
The "Breaks and Retests - Free990" strategy is based on identifying breakout and retest opportunities for potential entries in both long and short trades. The idea is to detect price breakouts above resistance levels or below support levels, and subsequently identify retests that confirm the breakout levels. The strategy offers an automated approach to enter trades after a breakout followed by a retest, which serves as a confirmation of trend continuation.
Key Components:
Support and Resistance Detection:
The strategy calculates pivot levels based on historical price movements to define support and resistance areas. A lookback range is used to determine these key levels.
Breakouts and Retests:
The system identifies when a breakout occurs above a resistance level or below a support level.
It then waits for a retest of the previously broken level as confirmation, which is often a better entry opportunity.
Trade Direction Selection:
Users can choose between "Long Only," "Short Only," or "Both" directions for trading based on their market view.
Stop Loss and Trailing Stop:
An initial stop loss is placed at a defined percentage away from the entry.
The trailing stop loss is activated after the position gains a specified percentage in profit.
Long Entry:
A long entry is triggered if the price breaks above a resistance level and subsequently retests that level successfully.
The entry condition checks if the breakout was confirmed and if a retest was valid.
The long entry is only executed if the user-selected direction is either "Long Only" or "Both."
Short Entry:
A short entry is triggered if the price breaks below a support level and subsequently retests that level.
The short entry is only executed if the user-selected direction is either "Short Only" or "Both."
sell_condition checks whether the support has been broken and whether the retest condition is valid.
An initial stop loss is placed when the trade is opened to limit the risk if the trade moves against the position.
The stop loss is calculated based on a user-defined percentage (stop_loss_percent) of the entry price.
pinescript
Copy code
stop_loss_price := strategy.position_avg_price * (1 - stop_loss_percent / 100)
For long positions, the stop loss is placed below the entry price.
For short positions, the stop loss is placed above the entry price.
Trailing Stop:
When a position achieves a certain profit threshold (profit_threshold_percent), the trailing stop mechanism is activated.
For long positions, the trailing stop follows the highest price reached, ensuring that some profit is locked in if the price reverses.
For short positions, the trailing stop follows the lowest price reached.
Code Logic for Trailing Stop:
Exit Execution:
The strategy exits the position when the price hits the calculated stop loss level.
This includes both the initial stop loss and the trailing stop that adjusts as the trade progresses.
Code Logic for Exit:
Summary:
Breaks and Retests - Free990 uses support and resistance levels to identify breakouts, followed by retests for confirmation.
Entry Points: Triggered when a breakout is confirmed and a retest occurs, for both long and short trades.
Exit Points:
Initial Stop Loss: Limits risk for both long and short trades.
Trailing Stop Loss: Locks in profits as the price moves in favor of the position.
This strategy aims to capture the momentum after breakouts and minimize losses through effective use of stop loss and trailing stops. It gives the flexibility of selecting trade direction and ensures trades are taken with confirmation through the retest, which helps to reduce false breakouts.
Original Code by @HoanGhetti