Pivot PointsPivot points are technical indicators used in financial markets (such as stocks, forex, or commodities) to identify potential turning points in price movement. They provide reference levels based on the previous day’s price action.
How to use the Pivot Points indicator
Traders use pivot points to identify significant price levels where the market may reverse or consolidate.
PP, S1, and R1 are considered primary levels, while S2 and R2 are secondary levels.
R3, R4, R5, S3, S4 and S5 are considered more extreme levels and we normally don't see price action trade near these levels on a typical day. This indicator calculates those extreme levels to help on days with extreme price action.
Pivot points can be calculated for different timeframes (daily, weekly, monthly, quarterly, 6-months and yearly).
Pivot points calculated using the daily timeframe is a popular chose among day traders traders who trade intraday timeframes.
Trading Strategies
Bounce Strategy:
Buy near support (S1 or S2) if the price bounces off these levels.
Sell near resistance (R1 or R2) if the price reverses from these levels.
Breakout Strategy:
If the price breaks above R1, consider a long position.
If the price breaks below S1, consider a short position.
Profit targets:
If in a long trade and price hits R1, you take some profit.
If in a short trade and price hits S1, you take some profit.
Combine pivot points with other technical indicators (e.g., moving averages, candlestick patterns) for confirmation. Remember that pivot points are just one tool among many, and their effectiveness varies across different markets and timeframes. Always practice risk management and consider the overall market context when using pivot points in your trading decisions.
Trend Analysis
MC vs Total MCMC vs Total MC
this is an edit of StableCoin MC vs Total MC by Crypto5Max supporting muti timeframes and addition dominances
is a powerful and versatile TradingView indicator designed to help traders and analysts visualize the dominance of different types of cryptocurrencies (StableCoin, AltCoin, BTC, ETH) relative to the total market capitalization. This indicator provides a clear and concise way to monitor market trends and make informed decisions based on the dominance of specific cryptocurrency segments.
Key Features:
Customizable Time Frames: Select from a variety of time frames including 5 Min, 15 Min, 30 Min, 1HR, 2HR, 4HR, 8HR, and Daily to tailor the analysis to your needs.
Dominance Type Selection: Choose the type of market capitalization dominance you want to track - StableCoins, AltCoins, Bitcoin, or Ethereum.
Total Market Capitalization Options: Analyze the market with different total market capitalization metrics - total crypto market cap, total market cap excluding BTC, or total market cap excluding BTC and ETH.
Dynamic Label Display: A label that follows the plotted dominance line and dynamically displays the dominance percentage, providing a clear visual representation.
Invisible Background Option: Choose to have an invisible background for a cleaner chart presentation.
How It Works:
Time Frame Selection: Use the time_frame input to choose the desired time frame for your analysis.
Dominance Type Selection: Select the type of dominance to display using the mcap_type input.
Total Market Capitalization Selection: Choose the total market capitalization metric with the total_sym input.
Dominance Calculation: The indicator calculates the dominance of the selected cryptocurrency type as a percentage of the total market capitalization.
Visual Display: The chosen dominance is plotted on the chart, and a label displaying the dominance percentage is dynamically updated to follow the plotted line.
Use Cases:
Market Trend Analysis: Identify trends in the dominance of StableCoins, AltCoins, BTC, or ETH to gauge market sentiment.
Portfolio Allocation: Make informed decisions about portfolio allocation by understanding the market share of different cryptocurrency types.
Technical Analysis: Combine with other technical indicators to enhance your trading strategy and gain deeper market insights.
This indicator is essential for traders, analysts, and investors who want to stay ahead of market movements and make data-driven decisions based on the dominance of various cryptocurrency segments.
Example:
If you select "AltCoin" as the dominance type and "Total 3" as the total market capitalization, the indicator will plot the dominance of AltCoins (excluding BTC and ETH) as a percentage of the total crypto market capitalization (excluding BTC and ETH) on the selected time frame. The dynamic label will display this percentage, updating as the market evolves.
Elevate your market analysis with the MC vs Total MC indicator and gain a comprehensive view of cryptocurrency dominance trends.
Supertrend Alert with Arrows and Time FilterOverview
This script is designed to generate trading signals based on the Supertrend indicator, a popular technical analysis tool. The Supertrend indicator is used to identify the direction of the market trend and potential reversal points.
Supertrend Settings
The script uses two sets of Supertrend settings:
Small Supertrend
Factor: 3.0
ATR Period: 10
Big Supertrend
Factor: 10.0
ATR Period: 30
These settings are fixed and should not be altered to maintain the integrity of the signal generation process.
Configurable Parameters
startHour: The hour at which signal generation begins.
endHour: The hour at which signal generation ends.
These parameters allow users to focus on specific trading hours, optimizing the signal relevance to their trading strategy.
Signal Types
The script generates two types of signals:
Type 1: Reversal Signal
Long Signal: Triggered when the big Supertrend is in an uptrend, and the small Supertrend transitions from a downtrend to an uptrend.
Short Signal: Triggered when the big Supertrend is in a downtrend, and the small Supertrend transitions from an uptrend to a downtrend.
Type 2: Trend Change Signal
Long Signal: Triggered when the big Supertrend changes from a downtrend to an uptrend.
Short Signal: Triggered when the big Supertrend changes from an uptrend to a downtrend.
How the Script Works
Initialization: The script initializes with predefined Supertrend settings.
Data Input: Market data (e.g., price data) is fed into the script.
Supertrend Calculation: The script calculates the Supertrend values using the predefined factors and ATR periods.
Signal Detection: The script monitors the Supertrend values and detects the defined signals based on the conditions mentioned above.
Time Filtering: Signals are filtered based on the specified startHour and endHour, ensuring only relevant signals are displayed within the desired timeframe.
Usage
Set Parameters: Define startHour and endHour according to your trading schedule.
Run Script: Execute the script with market data input.
Interpret Signals: Monitor the generated signals and use them to inform your trading decisions.
Originality
Dual Supertrend Usage: The use of both a small and a big Supertrend to generate signals adds a layer of complexity and reliability to the signals.
Time-Based Filtering: Allows traders to focus on specific trading hours, enhancing the relevance and accuracy of signals.
Two Signal Types: The combination of reversal signals and trend change signals provides comprehensive market insights.
Conclusion
This Supertrend Signal Generator is a robust tool for traders seeking to leverage the Supertrend indicator for more informed trading decisions. By combining dual Supertrend settings and configurable trading hours, the script offers unique and flexible signal generation capabilities.
RvB ( relative strength vs BTC ) Overview
The "Coin vs BTC" indicator is designed to compare the performance of a selected cryptocurrency against Bitcoin (BTC) using Exponential Moving Averages (EMAs). By plotting the difference in EMA values as a percentage, this indicator helps traders visualize the relative strength of a cryptocurrency compared to Bitcoin over specified periods.
How It Works
EMA Calculation: The indicator calculates two EMAs (lengths specified by the user) for both the selected cryptocurrency and Bitcoin (BTC).
Length 1: Fast EMA (default: 9)
Length 2: Slow EMA (default: 21)
Score Calculation:
For both the selected coin and Bitcoin, it computes a score representing the percentage difference between the fast and slow EMAs relative to the previous closing price. This is done using the following steps:
Calculate the difference between the fast and slow EMAs.
Compute the percentage of this difference relative to the previous closing price.
Round the percentage to two decimal places for clarity.
Plotting: The scores for both the selected cryptocurrency and Bitcoin are plotted on the same chart:
Coin Score: Displayed in blue.
BTC Score: Displayed in orange.
Potential Uses
Relative Strength Analysis:
This indicator helps traders compare the strength of a cryptocurrency against Bitcoin. A higher score for the selected coin compared to Bitcoin indicates it is performing better relative to its moving averages.
Trend Confirmation:
By observing the EMA differences, traders can confirm trends and potential reversals. Consistently higher scores may indicate a strong upward trend, while lower scores could suggest a weakening trend.
Market Comparison:
This tool is particularly useful for those looking to understand how their selected cryptocurrency is performing in the broader market context, especially in relation to Bitcoin, which is often considered a market benchmark.
Candle Strength Oscillator by SyntaxGeekThis candle strength oscillator displays a smoothed rolling difference between the body range (close and open) and total candle range (high and low).
When candles have small bodies, such as a doji, it can indicate weakness, when candles have essentially little to no wicks it can indicate strength.
There are two modes of display for the strength trend to show potential exhaustion on either side, bollinger bands and donchian channels. Each has their own pros and cons but as most are familiar with bollinger bands this is the default.
Another feature is the ATR measurement, which can assist in displaying an overall reduction in range volatility when comparing historical price movements to current oscillations.
The zero line can show some importance with regards to the peaks and valleys of the main measurement, when everything is trending and there's a reversal, if the zero line isn't broken it could be considered a trend continuation pullback vs a complete reversal.
Trend arrows and bar coloring are available but should not be considered trade signals for entry and exit, merely just another way of viewing the lower study information.
As the raw data of each candle measurement is quite noisy, the entire dataset is passed through an HMA smoothing process, if more options are requested I'll consider adding them.
Thanks for view my script and happy trading!
Ticker Performance ComparisonTicker Performance Comparison Indicator
With this tool you can compare how three different tickers of your choice have performed over a specific period you choose. It can be used on any timeframe.
As you can see in the image above, I am comparing Nvidia, Bitcoin and Wadzpay over a 365 day period. This shows me at glance which asset has done better and by how much.
It shows how the closing prices have changed from the start of your chosen period to now, by automatically drawing lines on the same scale.
Key Features:
Lookback Period: You decide how many bars (days, weeks, etc.) back to look from today.
Three Tickers: Enter up to three different ticker symbols to see how they stack up against each other
Percentage Change: The tool calculates how much each ticker's closing price has changed, in percentage terms, from the start of your lookback period.
Performance Labels: Labels at the end of the period show the percentage change for each ticker.
Important:
Ignore the lines that are drawn before your lookback period: The lines before your chosen lookback period might be misleading. They appear due to the way historical data is processed and should be ignored. Only consider the data and trends from the start of the lookback period you entered to the present for an accurate comparison.
Use this tool to easily compare how different assets have performed over the timeframe that matters to you.
Moving Average Bands with Signals [UAlgo]The "Moving Average Bands with Signals combines various moving average types with ATR-based bands to help traders identify potential support and resistance levels.
It plots moving average bands with upper and lower support/resistance levels based on the Average True Range (ATR) and user-defined settings.Additionally, the script generates buy/sell signals based on price crossing above or below the bands.
🔶 Key Features
Multiple Moving Average Types:
Supports various moving average calculations including Arnaud Legoux Moving Average (ALMA), Exponential Moving Average (EMA), Double Exponential Moving Average (DEMA), Triple Exponential Moving Average (TEMA), Kaufman Adaptive Moving Average (KAMA), Hull Moving Average (HMA), Least Squares Moving Average (LSMA), Simple Moving Average (SMA), Triangular Moving Average (TMA), Volume-Weighted Moving Average (VWMA), Weighted Moving Average (WMA), and Zero-Lag Moving Average (ZLMA).
Customizable ATR Bands:
Integrates the Average True Range (ATR) to calculate dynamic support and resistance bands around the moving average. The multiplier for the bands is user-adjustable, allowing for finer control over the sensitivity and width of the bands.
Signal Generation:
Provides visual signals on the chart when the price interacts with the support or resistance bands. Users can choose between using the wick or the close price to generate these signals, adding an extra layer of customization based on their trading style.
Flexible Input Parameters:
Allows users to input parameters for moving average length, ATR length, band multiplier, and signal type. Additional settings are available for specific moving average types, such as ALMA's offset and sigma, KAMA's fast and slow periods, and LSMA's offset.
🔶 Disclaimer
This script is provided for educational purposes only and should not be considered financial advice.
Trading financial instruments involves substantial risk and can result in significant financial losses.
The script’s performance in the past is not indicative of future results, and no guarantees are made regarding its accuracy, reliability, or performance.
F.B_Volume Weighted Average Price MTFThe F.B_Volume Weighted Average Price MTF (VWAP MTF) indicator calculates the volume-weighted average price of a security across different timeframes. The VWAP is a powerful indicator used by both institutional and retail traders to make better trading decisions.
Functionality:
Timeframe:
The indicator allows you to adjust the timeframe for the VWAP calculation via the settings. By default, the timeframe is set to weekly ("W").
Restart at new timeframe:
At each new period in the chosen timeframe, the VWAP calculations are reset, and a new VWAP is calculated.
VWAP Calculation:
The VWAP is calculated by the volume-weighted average of the typical prices (High, Low, and Close) of the security. This calculation takes into account the volume of each transaction to provide an accurate average price.
Visualization:
The VWAP is displayed as a line on the chart, and the color of the line changes depending on the price position relative to the VWAP:
Green: The current closing price is above the VWAP (bullish signal).
Red: The current closing price is below the VWAP (bearish signal).
Options:
Show barcolors:
This option allows you to display the colors of the candles based on their position relative to the VWAP (green for bullish, red for bearish).
Show previous VWAP close:
This option shows the closing value of the VWAP from the previous period to provide historical reference points.
Interpretation:
Bullish Signal:
If the current price is above the VWAP, this indicates that the market trend is upward, which could be considered a buying opportunity.
Bearish Signal:
If the current price is below the VWAP, this indicates that the market trend is downward, which could be considered a selling signal.
Cot Histogram | MercorCot Histogram | Mercor
Overview:
The Cot Histogram | Mercor indicator provides a comprehensive visualization of the Commitment of Traders (COT) report data using bar charts. This indicator is designed to help traders analyze the positions held by commercial traders and large speculators in various markets. By representing the data as histograms, traders can easily interpret the long and short positions, as well as the net positions of these market participants.
Originality:
What sets the Cot Histogram | Mercor indicator apart is its unique approach to visualizing COT data using bar charts instead of traditional line charts. This method offers a clearer representation of the data, making it easier for traders to spot trends and changes in market sentiment. Additionally, the indicator allows for customization of colors and bar widths, providing a tailored experience for each user.
Features:
Show Shorts as Negative Numbers: This option allows users to display short positions as negative values, providing a more intuitive visualization.
Invert Colors: Users can invert the default colors for long and short positions, enabling better contrast and visual preference.
Bar Width: Adjust the width of the histogram bars to suit personal preferences and chart aesthetics.
Concepts Underlying the Calculations:
The Commitment of Traders (COT) report is a weekly publication by the Commodity Futures Trading Commission (CFTC) that provides a breakdown of the open interest positions of market participants in futures markets. This indicator focuses on two main categories of traders:
Commercial Traders: These are entities involved in the production, processing, or merchandising of a commodity. Their positions are typically hedging-oriented.
Large Speculators: These include institutional investors, hedge funds, and other entities that take positions based on market trends and expectations, often for speculative purposes.
The indicator calculates and plots the following metrics:
Commercial Long: The number of long positions held by commercial traders.
Commercial Short: The number of short positions held by commercial traders.
Commercial Net: The difference between commercial long and short positions.
Large Speculators Long: The number of long positions held by large speculators.
Large Speculators Short: The number of short positions held by large speculators.
Large Speculators Net: The difference between long and short positions of large speculators.
How to Use:
Load the Indicator: Add the Cot Histogram | Mercor indicator to your TradingView chart.
Customize Settings: Adjust the settings according to your preferences:
Enable or disable the "Show Shorts as Negative Numbers" option.
Invert the colors if needed.
Adjust the bar width for better visual representation.
Interpret the Data: Use the histograms to analyze the market positions:
Commercial Long and Short: Observe the positions held by commercial traders. Increasing long positions may indicate hedging against potential price increases, while increasing short positions may suggest hedging against potential price decreases.
Large Speculators Long and Short: Monitor the positions of large speculators to gauge market sentiment. A rise in long positions by large speculators often indicates bullish sentiment, while a rise in short positions suggests bearish sentiment.
Net Positions: The net positions provide a clearer picture of the overall stance of commercial traders and large speculators.
Example:
If you notice that commercial traders are increasing their long positions while large speculators are increasing their short positions, it may indicate a divergence in market expectations between hedgers and speculators. This could be a signal to further investigate potential market reversals or confirm existing trends.
By leveraging the Cot Histogram | Mercor indicator, traders can gain valuable insights into market dynamics, improve their trading strategies, and make more informed decisions. Whether you are a long-term investor or a short-term trader, understanding the positions of different market participants can provide a significant edge in the markets.
Auto Gann KEYLVLS "Auto Gann KEYLVLS" indicator can be a valuable tool for traders, especially those who employ Gann theory in their analysis. Here are some ways to effectively use this indicator:
Identifying Key Price Levels: Gann lines are known for their ability to identify key support and resistance levels. Use the plotted Gann lines to identify significant price levels where the market may react.
Confirmation of Trend Reversals: When price approaches a Gann line, observe how the price reacts. A bounce off a Gann line can confirm the continuation of the trend, while a break of a Gann line may indicate a potential trend reversal.
Entry and Exit Points: Gann lines can serve as entry and exit points for trades. Look for confluence between Gann lines and other technical indicators or patterns to identify high-probability trade setups.
Trading with the Trend: In an uptrend, consider buying opportunities near Gann support levels, while in a downtrend, look for selling opportunities near Gann resistance levels.
Risk Management: Use Gann lines to set stop-loss and take-profit levels. Place stop-loss orders below Gann support levels for long trades and above Gann resistance levels for short trades to manage risk effectively.
Timeframe Analysis: Utilize the flexibility of this indicator to plot Gann lines on different timeframes. Compare Gann lines across multiple timeframes to identify alignment or divergence, which can provide additional confirmation for trading decisions.
Combination with Other Indicators: Combine the information provided by Gann lines with other technical indicators, such as moving averages, RSI, or MACD, to strengthen your trading decisions.
Input Parameters:
The script defines several input parameters that control the behavior of the Gann lines, such as the number of weeks to look back for highs and lows, the number of Gann lines to plot, line extension settings, and options to show or hide specific Gann lines like .25, .37, .50, .63, and .75.
Auto Gann Functionality:
The script calculates the highest high and lowest low for the specified number of weeks, hours, and minutes.
It then calculates quartile levels (0.25, 0.50, 0.75) based on the weekly high and low.
Gann lines are drawn based on these levels, with options to extend them left and/or right.
Labels are added to the Gann lines indicating their values.
Weekly Gann Lines:
The script plots Gann lines and labels based on the weekly high and low levels.
Labels are added to these lines indicating their values.
Sub Gann Lines:
Additional Gann lines are plotted based on the weekly high and low levels, with subdivisions for lower timeframes like H4, H1, M15, and M1.
Label Management:
Labels are managed based on user preferences, including options to show labels once on the left side, redraw labels on the right side, or not show labels at all.
BBTrend w SuperTrend decision - Strategy [presentTrading]This strategy aims to improve upon the performance of Traidngview's newly published "BB Trend" indicator by incorporating the SuperTrend for better trade execution and risk management. Enjoy :)
█Introduction and How it is Different
The "BBTrend w SuperTrend decision - Strategy " is a trading strategy designed to identify market trends using Bollinger Bands and SuperTrend indicators. What sets this strategy apart is its use of two Bollinger Bands with different lengths to capture both short-term and long-term market trends, providing a more comprehensive view of market dynamics. Additionally, the strategy includes customizable take profit (TP) and stop loss (SL) settings, allowing traders to tailor their risk management according to their preferences.
BTCUSD 4h Long Performance
█ Strategy, How It Works: Detailed Explanation
The BBTrend strategy employs two key indicators: Bollinger Bands and SuperTrend.
🔶 Bollinger Bands Calculation:
- Short Bollinger Bands**: Calculated using a shorter period (default 20).
- Long Bollinger Bands**: Calculated using a longer period (default 50).
- Bollinger Bands use the standard deviation of price data to create upper and lower bands around a moving average.
Upper Band = Middle Band + (k * Standard Deviation)
Lower Band = Middle Band - (k * Standard Deviation)
🔶 BBTrend Indicator:
- The BBTrend indicator is derived from the absolute differences between the short and long Bollinger Bands' lower and upper values.
BBTrend = (|Short Lower - Long Lower| - |Short Upper - Long Upper|) / Short Middle * 100
🔶 SuperTrend Indicator:
- The SuperTrend indicator is calculated using the average true range (ATR) and a multiplier. It helps identify the market trend direction by plotting levels above and below the price, which act as dynamic support and resistance levels. * @EliCobra makes the SuperTrend Toolkit. He is GOAT.
SuperTrend Upper = HL2 + (Factor * ATR)
SuperTrend Lower = HL2 - (Factor * ATR)
The strategy determines market trends by checking if the close price is above or below the SuperTrend values:
- Uptrend: Close price is above the SuperTrend lower band.
- Downtrend: Close price is below the SuperTrend upper band.
Short: 10 Long: 20 std 2
Short: 20 Long: 40 std 2
Short: 20 Long: 40 std 4
█ Trade Direction
The strategy allows traders to choose their trading direction:
- Long: Enter long positions only.
- Short: Enter short positions only.
- Both: Enter both long and short positions based on market conditions.
█ Usage
To use the "BBTrend - Strategy " effectively:
1. Configure Inputs: Adjust the Bollinger Bands lengths, standard deviation multiplier, and SuperTrend settings.
2. Set TPSL Conditions: Choose the take profit and stop loss percentages to manage risk.
3. Choose Trade Direction: Decide whether to trade long, short, or both directions.
4. Apply Strategy: Apply the strategy to your chart and monitor the signals for potential trades.
█ Default Settings
The default settings are designed to provide a balance between sensitivity and stability:
- Short BB Length (20): Captures short-term market trends.
- Long BB Length (50): Captures long-term market trends.
- StdDev (2.0): Determines the width of the Bollinger Bands.
- SuperTrend Length (10): Period for calculating the ATR.
- SuperTrend Factor (12): Multiplier for the ATR to adjust the SuperTrend sensitivity.
- Take Profit (30%): Sets the level at which profits are taken.
- Stop Loss (20%): Sets the level at which losses are cut to manage risk.
Effect on Performance
- Short BB Length: A shorter length makes the strategy more responsive to recent price changes but can generate more false signals.
- Long BB Length: A longer length provides smoother trend signals but may be slower to react to price changes.
- StdDev: Higher values create wider bands, reducing the frequency of signals but increasing their reliability.
- SuperTrend Length and Factor: Shorter lengths and higher factors make the SuperTrend more sensitive, providing quicker signals but potentially more noise.
- Take Profit and Stop Loss: Adjusting these levels affects the risk-reward ratio. Higher take profit percentages can increase gains but may result in fewer closed trades, while higher stop loss percentages can decrease the likelihood of being stopped out but increase potential losses.
ICT KillZones Hunt [TradingFinder] 4 Sessions + OB + FVG + Alert🔵 Introduction
🟣 ICT
The "ICT" style is a subset of "Price Action" technical analysis. The primary goal of the ICT trading strategy is to merge "Price Action" with the "Smart Money" concept to pinpoint optimal trade entry points.
However, this approach's strength extends beyond merely finding entry points. It also helps traders gain a deeper understanding of price behavior and adapt their trading strategies to the market structure.
The most important concepts of "ICT" :
Order Block
Fair Value Gap(FVG)
Liquidity
🟣 Session
Financial markets are divided into several time periods, each featuring distinct characteristics and levels of activity. These periods, known as sessions, are active at different times during the day.
The primary active sessions in financial markets include :
Asian Session
European Session
New York Session
Based on the UTC time zone, the schedule for these key sessions is :
Asian Session: 23:00 to 06:00
European Session: 07:00 to 16:30
New York Session: 13:00 to 22:00
Note
To avoid session overlap and minimize interference during kill zones, the session times have been modified as follows :
Asian Session: 23:00 to 06:00
European Session: 07:00 to 14:25
New York Session: 14:30 to 22:55
🟣 KillZone
Kill zones are periods within a session where trader activity spikes. During these times, trading volume surges, and price movements become more pronounced.
The major kill zones, according to the UTC time zone, are as follows :
Asian Kill Zone: 23:00 to 03:55
European Kill Zone: 07:00 to 09:55
New York Morning Kill Zone: 14:30 to 16:55
New York Evening Kill Zone: 19:30 to 20:55
🔵 How to Use
🟣 Order Block
Order blocks are a distinct category of "Supply and Demand" zones, formed when a series of orders are grouped together. These blocks are often created by banks or other significant market participants.
Banks typically execute large orders in blocks during their trading sessions. If they were to enter the market with small quantities, substantial price movements would occur before the orders were fully executed, reducing potential profit.
To mitigate this, they divide their orders into smaller, more manageable positions. Traders should seek "buy" opportunities in "demand order blocks" and "sell" opportunities in "supply order blocks."
🟣 Fair Value Gap (FVG)
To pinpoint the "Fair Value Gap" on the chart, meticulous candle-by-candle analysis is essential. Pay close attention to candles with significant bodies, examining each candle alongside the one preceding it.
The candles flanking this central candle should exhibit elongated shadows, with bodies that do not intersect the body of the central candle. The span between the shadows of the first and third candles is referred to as the FVG range.
Note :
The origin of all Order Blocks and FVGs starts from inside a kill zone and extends up to the end of the same session.
🟣 Kill Zone Hunt
Following this strategy, after the conclusion of the kill zone and the stabilization of its high and low lines, if the price touches either of these lines within the same session and encounters a robust rejection, it presents an opportunity to enter a trade.
🔵 Setting
🟣 Global Setting
Show All Order Block :
If it is turned off, only the last Order Block will be displayed.
Show All FVG :
If it is turned off, only the last FVG will be displayed.
Show More Info Session :
If it is turned on, more information about kill zones (Trade Volume, Time, Number of Candles) will be displayed.
🟣 Logic Parameter
Pivot Period of Order Blocks Detector :
Enter the desired pivot period to identify the Order Block.
Order Block Validity Period (Bar) :
You can specify the maximum time the Order Block remains valid based on the number of candles from the origin.
Mitigation Level Order Block :
Determining the basic level of a block order. When the price hits the basic level, the order block due to mitigation.
🟣 Order Blocks Display
Demand Order Block :
Show or not show and specify color.
Supply order Block :
Show or not show and specify color.
🟣 Order Block Refinement
Refine Demand OB :
Enable or disable the refinement feature. Mode selection.
Refine Supply OB :
Enable or disable the refinement feature. Mode selection.
🟣 FVG
FVG Validity Period (Bar) :
You can specify the maximum time the FVG remains valid based on the number of candles from the origin.
Mitigation Level FVG :
Determining the basic level of a FVG. When the price hits the basic level, the FVG due to mitigation.
Show Demand FVG :
Show or not show and specify color.
Show Supply FVG :
Show or not show and specify color.
FVG Filter :
Enable or disable filtering of FVGs. Select filter mode.
🟣 Session
Show More Info Session Color
Asia Session, London Sesseion, New York am Session & New York pm Session :
Show or not show session and kill zones. Change the display color.
🟣 Alert
Send Alert When Touched Session high & Low :
On / Off
Alert Demand OB Mitigation :
On / Off
Alert Supply OB Mitigation :
On / Off
Alert Demand FVG Mitigation :
On / Off
Alert Supply FVG Mitigation :
On / Off
Message Frequency :
This string parameter defines the announcement frequency. Choices include: "All" (activates the alert every time the function is called), "Once Per Bar" (activates the alert only on the first call within the bar), and "Once Per Bar Close" (the alert is activated only by a call at the last script execution of the real-time bar upon closing). The default setting is "Once per Bar".
Show Alert Time by Time Zone :
The date, hour, and minute you receive in alert messages can be based on any time zone you choose. For example, if you want New York time, you should enter "UTC-4". This input is set to the time zone "UTC" by default.
Display More Info :
Displays information about the price range of the order blocks (Zone Price) and the date, hour, and minute under "Display More Info". If you do not want this information to appear in the received message along with the alert, you should set it to "Off".
ATH/ATL Tracker [LuxAlgo]The ATH/ATL Tracker effectively displays changes made between new All-Time Highs (ATH)/All-Time Lows (ATL) and their previous respective values, over the entire history of available data.
The indicator shows a histogram of the change between a new ATH/ATL and its respective preceding ATH/ATL. A tooltip showing the price made during a new ATH/ATL alongside its date is included.
🔶 USAGE
By tracking the change between new ATHs/ATLs and older ATHs/ATLs, traders can gain insight into market sentiment, breadth, and rotation.
If many stocks are consistently setting new ATHs and the number of new ATHs is increasing relative to old ATHs, it could indicate broad market participation in a rally. If only a few stocks are reaching new ATHs or the number is declining, it might signal that the market's upward momentum is decreasing.
A significant increase in new ATHs suggests optimism and willingness among investors to buy at higher prices, which could be considered a positive sentiment. On the other hand, a decrease or lack of new ATHs might indicate caution or pessimism.
By observing the sectors where stocks are consistently setting new ATHs, users can identify which sectors are leading the market. Sectors with few or no new ATHs may be losing momentum and could be identified as lagging behind the overall market sentiment.
🔶 DETAILS
The indicator's main display is a histogram-style readout that displays the change in price from older ATH/ATLs to Newer/Current ATH/ATLs. This change is determined by the distance that the current values have overtaken the previous values, resulting in the displayed data.
The largest changes in ATH/ATLs from the ticker's history will appear as the largest bars in the display.
The most recent bars (depending on the selected display setting) will always represent the current ATH or ATL values.
When determining ATH & ATL values, it is important to filter out insignificant highs and lows that may happen constantly when exploring higher and lower prices. To combat this, the indicator looks to a higher timeframe than your chart's timeframe in order to determine these more significant ATHs & ATLs.
For Example: If a user was on a 1-minute chart and 5 highs-new highs occur across 5 adjacent bars, this has the potential to show up as 5 new ATHs. When looking at a higher timeframe, 5 minutes, only the highest of the 5 bars will indicate a new ATH. To assist with this, the indicator will display warnings in the dashboard when a suboptimal timeframe is selected as input.
🔹 Dashboard
The dashboard displays averages from the ATH/ATL data to aid in the anticipation and expectations for new ATH/ATLs.
The average duration is an average of the time between each new ATH/ATL, in this indicator it is calculated in "Days" to provide a more comprehensive understanding.
The average change is the average of all change data displayed in the histogram.
🔶 SETTINGS
Duration: The designated higher timeframe to use for filtering out insignificant ATHs & ATLs.
Order: The display order for the ATH/ATL Bars, Options are to display in chronological (oldest to newest) or reverse chronological order (newest to oldest).
Bar Width: Sets the width for each ATH/ATL bar.
Bar Spacing: Sets the # of empty bars in between each ATH/ATL bar.
Dashboard Settings: Parameters for the dashboard's size and location on the chart.
Death Cross and Golden Cross HighlighterOverview
The script is designed to visually indicate the occurrence of Death Cross and Golden Cross events on a TradingView chart. It achieves this by calculating two moving averages (short-term and long-term) and plotting them on the chart. It then detects when these moving averages cross and highlights these points with labels and background colors.
Inputs
The script begins by defining input parameters:
- Short Moving Average Length: This is set to 50 by default, representing the short-term moving average period.
- Long Moving Average Length: This is set to 200 by default, representing the long-term moving average period.
These inputs allow users to customize the lengths of the moving averages according to their trading strategy.
Moving Averages Calculation
The script calculates two simple moving averages (SMAs) based on the closing prices:
- Short Moving Average (shortMA): Calculated over the short-term period specified by the user.
- Long Moving Average (longMA): Calculated over the long-term period specified by the user.
Plotting the Moving Averages
The moving averages are then plotted on the chart:
- The short-term moving average is plotted in blue.
- The long-term moving average is plotted in red.
These lines help users visually track the trends and potential crossover points.
Identifying Crossovers
The script identifies two key events:
- Golden Cross: Occurs when the short-term moving average crosses above the long-term moving average. This is typically considered a bullish signal, indicating a potential upward trend.
- Death Cross: Occurs when the short-term moving average crosses below the long-term moving average. This is typically considered a bearish signal, indicating a potential downward trend.
Highlighting Crossovers
To make the crossover events more noticeable, the script adds visual cues:
- Golden Cross: When a Golden Cross is detected, a green label with an upward arrow is plotted below the bar where the crossover occurs.
- Death Cross: When a Death Cross is detected, a red label with a downward arrow is plotted above the bar where the crossover occurs.
Background Coloring
Additionally, the script highlights the background of the chart:
- When a Golden Cross occurs, the background color is changed to a translucent green.
- When a Death Cross occurs, the background color is changed to a translucent red.
These background colors help emphasize the crossover events, making them easier to spot.
Usage
To use this script, a user would:
1. Copy the script and paste it into the Pine Script editor on TradingView.
2. Save the script and apply it to their chart.
By doing so, the user will see the moving averages plotted, and any Golden Cross or Death Cross events will be highlighted with labels and background colors. This visual aid helps traders quickly identify significant crossover events, which can inform their trading decisions.
Trend Strength Signals [AlgoAlpha]🌟Introducing the Trend and Strength Signals indicator by AlgoAlpha ! This tool is designed to help you identify trends and gauge market strength with precision and ease. 📈🚀
🛠 Customizable Parameters : Adjust the period, standard deviation multiplier, gauge size, and colors to fit your trading style.
📊 Trend Detection : Visualize trends with clear color-coded signals for uptrends and downtrends.
📈 Strength Gauge : Assess market strength with a dynamic gauge that adapts to the current price action.
🔔 Alerts : Set alerts for bullish and bearish trend crossovers and take profit points to stay ahead of the market.
🎨 Visual Enhancements : Enjoy a clutter-free chart with the integration of plot shapes, color fills, and gradient gauges.
🚀 Quick Guide to Using the Trend and Strength Signals Indicator
Maximize your trading with the Trend and Strength Signals indicator by following these streamlined steps! 🎯✨
🛠 Add the Indicator : Add the indicator to your favorites. Customize settings like period, standard deviation multiplier, and colors to fit your trading style.
📊 Market Analysis : Observe the color-coded candles and gauge to understand market trend direction and strength. Use the alerts for key trading signals.
🔔 Alerts : Enable notifications for trend crossovers and take profit points to catch trading opportunities without constantly monitoring the chart.
⚙️ How it works
This indicator calculates the moving average and standard deviation of the closing price over a customizable period to identify the upper and lower bounds. When the price crosses these bounds, it signals an uptrend or downtrend. The gauge measures market strength by comparing the price to the moving average and scaling it over a customizable range, while the underlying logic uses concepts from the Bollinger Bands, this indicator gives a unique perspective on price behavior through added features and signals derived from it.
Unleash the power of trend and strength analysis with this comprehensive indicator! Happy trading! 🚀📈✨
Low and High Values [Alorse]🌟 What does this indicator do?
This magical indicator shows you the lowest (Low) and highest (High) values of the last X candles directly on your chart. Not only that, but it also tells you how much the price has changed from the opening price of the current candle to these key points, all in percentage format. You'll have a clear and precise view of market movement!
🔧 Customize to your liking
Want to adjust the number of candles to consider? No problem! You can easily change this parameter to suit your preference. Whether you like short-term strategies with just a few candles or prefer more extensive analysis with many candles, our indicator adapts to you.
🚀 How can this indicator help you?
Identify Support and Resistance: By showing the lowest and highest points, it helps you identify key support and resistance levels. Perfect for planning your entries and exits!
Trend Analysis: With the percentage labels, you can quickly see how the price has moved relative to recent extremes, helping you confirm trends or anticipate possible reversals.
Trading Strategies: Imagine the price is near a recent low, but the percentage indicates a significant drop from the opening. This could be a buy signal if you expect a rebound. Conversely, if the price is near a recent high with a large percentage increase, you might consider selling.
Calculate Stop Loss: Use this indicator to determine your Stop Loss levels by leaving a bit of margin between the indicator value and your desired SL. This helps protect your positions while allowing for some price fluctuation.
📊 Examples of Use
Intraday Trader: Use the indicator with 10-20 candles to capture quick moves and capitalize on daily fluctuations.
Mid-term Trader: Set the indicator to consider 50 candles for a broader view of trends and reversal points.
Long-term Strategist: Adjust the indicator to 100 candles or more to identify highs and lows over larger time frames.
🛠️ Customizable Parameters
Number of Candles: Define the number of candles the indicator will analyze to calculate the lowest and highest values. It's all up to you!
Volume-Enhanced Momentum Moving Average (VEMMA)Volume-Enhanced Momentum Moving Average (VEMMA)
Overview:
The Volume-Enhanced Momentum Moving Average (VEMMA) helps you spot market trends by combining momentum and volume as a moving average. This unique moving average adjusts itself based on the strength and activity of the market, giving you a clearer picture of what’s happening.
How It Works:
1. Key Settings (all of these are adjustable in the settings panel of the indicator):
◦ Base Length: Looks back over the last 50 days by default.
◦ Momentum Length: Uses the past 14 days to measure market strength.
◦ Volume Length: Uses the past 30 days to average trading volume.
◦ High/Low Thresholds: Considers RSI values above 70 as high momentum and below 30 as low momentum.
2. Momentum and Volume:
◦ Momentum: Calculated using the Relative Strength Index (RSI) to see if the market is gaining or losing strength.
◦ Volume: Average trading volume is calculated over the last 30 days to gauge trading activity.
3. VEMMA Calculation:
◦ For each of the past 50 days:
▪ Check Momentum: If RSI > 70, it’s high momentum; if RSI < 30, it’s low.
▪ Weight by Volume: High momentum days with high volume get more weight; low momentum days get less.
▪ Combine: Multiply the closing price by this weight and sum it up.
◦ Average: Divide the total by 50 to get the VEMMA value.
4. Visuals:
◦ Lines: Two lines, VEMMA1 (blue) and VEMMA2 (orange), show the adjusted moving averages.
◦ Colours: Background colors help you quickly spot high (green) and low (red) momentum periods.
How to Use:
• Spot Trends: Rising VEMMA lines suggest an uptrend; falling lines suggest a downtrend.
• Confirm Signals: When both VEMMA1 and VEMMA2 move together, it indicates a strong trend.
• Identify Reversals: Watch for background color changes from green to red or vice versa to catch potential trend reversals.
If the market has been strong and active, the VEMMA line will rise more sharply. If the market is weak and quiet, the line will be smoother.
Benefits:
• Integrated View: Combines market strength and trading activity for a fuller picture.
• Responsive: Adapts to significant market changes, highlighting key movements.
• Easy to Read: Clear visuals with color-coded backgrounds make interpretation simple.
Remember, just like any other indicator, this is not supposed to be used alone. Use it as part of your greater trading strategy. I do however believe it works exceptionally well for finding longer term trends early. The default VEMMA settings work very well as replacement for the EMA 200. Try it and see how it goes. Play around with the settings. Feedback appreciated.
Enhanced Reversal DetectionScript Description:
The "Enhanced Reversal Detection" indicator is a powerful tool designed to identify potential market reversals across various financial instruments. It incorporates a sophisticated algorithm that analyzes price action along with key technical indicators such as the Relative Strength Index (RSI), Bollinger Bands, and Moving Average (MA).
How to Use:
Adjustable Parameters: The indicator offers a range of adjustable parameters to cater to different trading preferences and market conditions.
RSI Length: Adjusts the length of the RSI calculation to fine-tune sensitivity.
Overbought Level: Sets the threshold for identifying overbought conditions on the RSI scale.
Oversold Level: Sets the threshold for identifying oversold conditions on the RSI scale.
Bollinger Bands Length: Determines the length of the Bollinger Bands calculation.
Bollinger Bands Multiplier: Adjusts the standard deviation multiplier for the Bollinger Bands, influencing band width.
Moving Average Length: Defines the length of the Moving Average calculation to capture trend direction.
Min Bars Between Signals: Sets the minimum number of bars required between consecutive reversal signals.
ADX Length: Adjusts the length of the Average Directional Index (ADX) calculation.
ADX Threshold: Defines the threshold value for ADX, serving as a filter for reversal signals.
Signal Generation: The indicator generates signals for both bullish and bearish reversals based on predefined criteria. A bullish reversal signal is triggered when the closing price exceeds the lower Bollinger Band and RSI falls below the oversold threshold. Conversely, a bearish reversal signal occurs when the closing price falls below the upper Bollinger Band and RSI surpasses the overbought threshold.
Alerts: Traders can opt to receive alerts for bullish and bearish reversal signals, enabling them to stay informed of potential trading opportunities even when away from the platform.
Publication Readiness:
To ensure readiness for publication in the TradingView public library, the script has been meticulously crafted and documented:
The code is extensively commented to provide clear explanations of parameters, calculations, and signal generation logic.
Best coding practices have been followed to enhance readability and maintainability.
Rigorous testing has been conducted to validate the accuracy and reliability of signal generation across various market conditions.
The script adheres to TradingView's guidelines and policies for script publication, ensuring compliance with platform standards and user expectations.
With its comprehensive features and user-friendly design, the "Enhanced Reversal Detection" indicator is poised to become a valuable asset for traders seeking to identify high-probability reversal opportunities in the financial markets.
ka66: FX Sessions High/LowThis indicator is specific to the 24-hour Forex Market. It provides 2 features:
Demarcating forex sessions with open and close lines. Note that looking at various sources online, we use the convention that the Asia session starts with the Tokyo market open, rather than the earlier Sydney session. Presumably this is better since we then have more liquidity in the market. Note that we have three sessions: Asia, London, New York.
At the end of each session, we begin plotting that (closed) session's high and low, which acts as a natural support and resistance for the Forex market. This is the key feature it provides. The first feature is mainly there for a visual guide, which can be turned off via the UI settings, but it certainly helps verifying the logic!
For more background, we are taking the idea of Previous Day High/Low (PDH/PDL), but adjusting it to a multi-session market like Forex. In essence, this is is a "Previous Session High/Low" indicator.
PDH/PDL works fine when you have a market with Regular Trading Hours, ignoring Extended Hours. However, in the Forex market, each session can have differing sentiments, e.g. we often see say London bringing prices up, and New York bringing them back down.
The break of session high/lows (or bouncing off them) can reflect where the potential direction price is going to take.
I also categorised this as a Sentiment indicator, because support and resistance areas where prices react do provide the sentiment of the market. They aren't just lines, they are prices of interest to major players.
Stock Rating [TrendX_]# OVERVIEW
This Stock Rating indicator provides a thorough evaluation of a company (NON-FINANCIAL ONLY) ranging from 0 to 5. The rating is the average of six core financial metrics: efficiency, profitability, liquidity, solvency, valuation, and technical ratings. Each metric encompasses several financial measurements to ensure a robust and holistic evaluation of the stock.
## EFFICIENCY METRICS
1. Asset-to-Liability Ratio : Measures a company's ability to cover its liabilities with its assets.
2. Equity-to-Liability Ratio : Indicates the proportion of equity used to finance the company relative to liabilities.
3. Net Margin : Shows the percentage of revenue that translates into profit.
4. Operating Expense : Reflects the costs required for normal business operations.
5. Operating Expense Ratio : Compares operating expenses to total revenue.
6. Operating Profit Ratio : Measures operating profit as a percentage of revenue.
7. PE to Industry Relative PE/PB : Compares the company's PE ratio to the industry average.
## PROFITABILITY METRICS
1. ROA : Indicates how efficiently a company uses its assets to generate profit.
2. ROE : Measures profitability relative to shareholders' equity.
3. EBITDA : Reflects a company's operational profitability.
4. Free Cash Flow Margin : Shows the percentage of revenue that remains as free cash flow.
5. Revenue Growth : Measures the percentage increase in revenue over a period.
6. Gross Margin : Reflects the percentage of revenue exceeding the cost of goods sold.
7. Net Margin : Percentage of revenue that is net profit.
8. Operating Margin : Measures the percentage of revenue that is operating profit.
## LIQUIDITY METRICS
1. Current Ratio : Indicates the ability to cover short-term obligations with short-term assets.
2. Interest Coverage Ratio : Measures the ability to pay interest on outstanding debt.
3. Debt-to-EBITDA : Compares total debt to EBITDA.
4. Debt-to-Equity Ratio : Indicates the relative proportion of debt and equity financing.
## SOLVENCY METRICS
1. Altman Z-score : Predicts bankruptcy risk
2. Beneish M-score : Detects earnings manipulation.
3. Fulmer H-factor : Predicts business failure risk.
## VALUATION METRICS
1. Industry Relative PE/PB Comparison : Compares the company's PE and PB ratios to industry averages.
2. Momentum of PE, PB, and EV/EBITDA Multiples : Tracks the trends of PE, PB, and EV/EBITDA ratios over time.
## TECHNICAL METRICS
1. Relative Strength Index (RSI) : Measures the speed and change of price movements.
2. Supertrend : Trend-following indicator that identifies market trends.
3. Moving Average Golden-Cross : Occurs when a short-term MA crosses above mid-term and long-term MA which are determined by half-PI increment in smoothing period.
4. On-Balance Volume Golden-Cross : Measures cumulative buying and selling pressure.
Cosine Kernel Regressions [QuantraSystems]Cosine Kernel Regressions
Introduction
The Cosine Kernel Regressions indicator (CKR) uses mathematical concepts to offer a unique approach to market analysis. This indicator employs Kernel Regressions using bespoke tunable Cosine functions in order to smoothly interpret a variety of market data, providing traders with incredibly clean insights into market trends.
The CKR is particularly useful for traders looking to understand underlying trends without the 'noise' typical in raw price movements. It can serve as a standalone trend analysis tool or be combined with other indicators for more robust trading strategies.
Legend
Fast Trend Signal Line - This is the foreground oscillator, it is colored upon the earliest confirmation of a change in trend direction.
Slow Trend Signal Line - This oscillator is calculated in a similar manner. However, it utilizes a lower frequency within the cosine tuning function, allowing it to capture longer and broader trends in one signal. This allows for tactical trading; the user can trade smaller moves without losing sight of the broader trend.
Case Study
In this case study, the CKR was used alongside the Triple Confirmation Kernel Regression Oscillator (KRO)
Initially, the KRO indicated an oversold condition, which could be interpreted as a signal to enter a long position in anticipation of a price rebound. However, the CKR’s fast trend signal line had not yet confirmed a positive trend direction - suggesting that entering a trade too early and without confirmation could be a mistake.
Waiting for a confirmed positive trend from the CKR proved beneficial for this trade. A few candles after the oversold signal, the CKR's fast trend signal line shifted upwards, indicating a strong upward momentum. This was the optimal entry point suggested by the CKR, occurring after the confirmation of the trend change, which significantly reduced the likelihood of entering during a false recovery or continuation of the downtrend.
This is one of the many uses of the CKR - by timing entries using the fast signal line , traders could avoid unnecessary losses by preventing premature entries.
Methodology
The methodology behind CKR is a multi-layered approach and utilizes many ‘base’ indicators.
Relative Strength Index
Stochastic Oscillator
Bollinger Band Percent
Chande Momentum Oscillator
Commodity Channel Index
Fisher Transform
Volume Zone Oscillator
The calculated output from each indicator is standardized and scaled before being averaged. This prevents any single indicator from overpowering the resulting signal.
// ╔════════════════════════════════╗ //
// ║ Scaling/Range Adjustment ║ //
// ╚════════════════════════════════╝ //
RSI_ReScale (_res ) => ( _res - 50 ) * 2.8
STOCH_ReScale (_stoch ) => ( _stoch - 50 ) * 2
BBPCT_ReScale (_bbpct ) => ( _bbpct - 0.5 ) * 120
CMO_ReScale (_chandeMO ) => ( _chandeMO * 1.15 )
CCI_ReScale (_cci ) => ( _cci / 2 )
FISH_ReScale (_fish1 ) => ( _fish1 * 30 )
VZO_ReScale (_VP, _TV ) => (_VP / _TV) * 110
These outputs are then fed into a customized cosine kernel regression function, which smooths the data, and combines all inputs into a single coherent output.
// ╔════════════════════════════════╗ //
// ║ COSINE KERNEL REGRESSIONS ║ //
// ╚════════════════════════════════╝ //
// Define a function to compute the cosine of an input scaled by a frequency tuner
cosine(x, z) =>
// Where x = source input
// y = function output
// z = frequency tuner
var y = 0.
y := math.cos(z * x)
Y
// Define a kernel that utilizes the cosine function
kernel(x, z) =>
var y = 0.
y := cosine(x, z)
math.abs(x) <= math.pi/(2 * z) ? math.abs(y) : 0. // cos(zx) = 0
// The above restricts the wave to positive values // when x = π / 2z
The tuning of the regression is adjustable, allowing users to fine-tune the sensitivity and responsiveness of the indicator to match specific trading strategies or market conditions. This robust methodology ensures that CKR provides a reliable and adaptable tool for market analysis.
Anchored Monte Carlo Shuffled Projection [LuxAlgo]The Anchored Monte Carlo Shuffled Projection tool randomly simulates future price points based on historical bar movements made before a user-anchored point in time.
By anchoring our data and projections to a single point in time, users can better understand and reflect on how the price played out while taking into consideration our random simulations.
🔶 USAGE
After selecting the indicator to apply to the chart, you will be prompted to "Set the Anchor Point". Do so by clicking on the desired location on your chart, only time is used as the anchor point.
Note: To select a new anchor point when applied to the chart, click on the 'More' dropdown next to the indicator status bar (○○○), then select "Reset points...".
Alternate Method: You are also able to click and drag the vertical line that displays on the anchor point bar when the indicator is highlighted.
By randomly simulating bar movements, a range is developed of potential price action which could be utilized to locate future price development as well as potential support/resistance levels.
Performing numerous simulations and taking the average at each step will converge toward the result highlighted by the "Average Line", and can point out where the price might develop, assuming the trend and amount of volatility persist.
Current closing price + Sum of changes in the calculation window
This constraint will cause the simulations always to display an endpoint consistent with the current lookback's slope.
While this may be helpful to some traders, this indicator includes an option to produce a less biased range, as seen below:
🔶 DETAILS
The Anchored Monte Carlo Shuffled Projection tool creates simulations based on prices within a user-set lookback window originating at the specified anchor point. Simulations are done as follows:
Collect each bar's price changes in the user-set window.
Randomize the order of each change in the window.
Project the cumulative sum of the shuffled changes from the current closing price.
Collect data on each point along the way.
This is the process for the Default calculation; for the 'Randomize Direction' calculation, when added onto the front for every other change, the value is inverted, creating the randomized endpoints for each simulation.
The script contains each simulation's data for that bar, with a maximum of 1000 simulations.
To get a glimpse behind the scenes, each simulation (up to 99) can be viewed using the 'Visualize Simulations' Options, as seen below.
Because the script holds the full simulation data, the script can also calculate this data, such as standard deviations.
In this script the Standard deviation lines are the average of all standard deviations across the vertical data groups, this provides a singular value that can be displayed a distance away from the simulation center line.
🔶 SETTINGS
Lookback: Sets the number of Bars to include in calculations.
Simulation Count: Sets the number of randomized simulations to calculate. (Max 1000)
Randomize Direction: See Details Above. Creates a more 'Normalized' Distribution
Visualize Simulations: See Details Above. Turns on Visualizations, and colors are randomly generated. Visualized max does not cap the calculated max. If 1000 simulations are used, the data will be from 1000 simulations, however, only the last 99 simulations will be visualized.
🔹 Standard Deviations
Standard Deviation Multiplier: Sets the multiplier to use for the Standard Deviation distance away from the center line.
🔹 Style
Extend Lines: Extends the Simulated Value Lines into the future for further reference and analysis.
[InvestorUnknown] Performance MetricsOverview
The Performance Metrics indicator is a tool designed to help traders and investors understand and utilize key performance metrics in their strategies. This indicator is inspired by the Rolling Risk-Adjusted Performance Ratios created by @EliCobra, but it offers enhanced usability and additional features to provide a more user-friendly code for understanding the calculations.
Features
Rolling Lookback:
Dynamic Lookback Calculation: The indicator automatically calculates the number of bars from the start of the asset's price history, up to a maximum of 5000 bars due to TradingView platform restrictions.
Adjustable Lookback Period: Users can manually set a lookback period or choose to use the rolling lookback feature for dynamic calculations.
RollingLookback() =>
x = bar_index + 1
y = x > 4999 ? 5000 : x > 1 ? (x - 1) : x
y
Trend Analysis
The Trend Analysis section in this indicator helps traders identify the direction of the market trend based on the balance of positive and negative returns over time. This is achieved by calculating the sums of positive and negative returns and optionally smoothing these values to provide a clearer trend signal.
Configuration: Enable smoothing if you want to reduce noise in the trend analysis. Choose between EMA and SMA for smoothing. Set the length for smoothing according to your preference for sensitivity (shorter lengths are more sensitive to changes, longer lengths provide smoother signals).
Interpretation:
- A positive trend difference (filled with green) indicates a bullish trend, suggesting more positive returns.
- A negative trend difference (filled with red) indicates a bearish trend, suggesting more negative returns.
- Colored bars provide a quick visual cue on the trend direction, helping to make timely trading decisions.
// The Trend Analysis section calculates and optionally smooths the sums of positive and negative returns.
// This helps identify the trend direction based on the balance of positive and negative returns over time.
Ps = Smooth ? Smooth_type == "EMA" ? ta.ema(pos_sum, Smooth_len) : ta.sma(pos_sum, Smooth_len) : pos_sum
Ns = Smooth ? Smooth_type == "EMA" ? ta.ema(neg_sum, Smooth_len) : ta.sma(neg_sum, Smooth_len) : neg_sum
// Calculate the difference between smoothed positive and negative sums
dif = Ps + Ns
Performance Metrics Table
Visual Table Display: Option to display a table on the chart with calculated performance metrics. This table includes comprehensive metrics like Mean Return, Positive and Negative Mean Return, Standard Deviation, Sharpe Ratio, Sortino Ratio, and Omega Ratio.
Performance Metrics Calculated
Mean Return:
Description: The average return over the lookback period.
Purpose: Helps in understanding the overall performance of the asset by providing a simple average of returns.
Positive Mean Return:
Description: The average of all positive returns over the lookback period.
Purpose: Highlights the average gain during profitable periods, giving insight into the asset's potential upside.
Negative Mean Return:
Description: The average of all negative returns over the lookback period.
Purpose: Focuses on the average loss during unprofitable periods, helping to assess the downside risk.
Standard Deviation (STDEV):
Description: A measure of volatility that calculates the dispersion of returns from the mean.
Purpose: Indicates the risk associated with the asset. Higher standard deviation means higher volatility and risk.
Sharpe Ratio:
Description: A risk-adjusted return metric that divides the mean return by the standard deviation of returns. It can be annualized if selected.
Purpose: Provides a standardized way to compare the performance of different assets by considering both return and risk. A higher Sharpe Ratio indicates better risk-adjusted performance.
sharpe_ratio = mean_all / stddev_all * (Annualize ? math.sqrt(Lookback) : 1)
Sortino Ratio:
Description: Similar to the Sharpe Ratio but focuses only on downside volatility. It divides the mean return by the standard deviation of negative returns. It can be annualized if selected.
Purpose: Offers a better assessment of downside risk by ignoring upside volatility. A higher Sortino Ratio indicates a higher return per unit of downside risk.
sortino_ratio = mean_all / stddev_neg * (Annualize ? math.sqrt(Lookback) : 1)
Omega Ratio:
Description: The ratio of the probability-weighted average of positive returns to the probability-weighted average of negative returns.
Purpose: Measures the overall likelihood of positive returns compared to negative returns. An Omega Ratio greater than 1 indicates more frequent and/or larger positive returns compared to negative returns.
omega_ratio = (prob_pos * mean_pos) / (prob_neg * -mean_neg)
By calculating and displaying these metrics, the indicator provides a comprehensive view of the asset's performance, enabling traders and investors to make informed decisions based on both returns and risk-adjusted metrics.
Use Cases:
Performance Evaluation: Assesses an asset's performance by analyzing both returns and risk factors, giving a clear picture of profitability and volatility.
Risk Comparison: Compares the risk-adjusted returns of different assets or portfolios, aiding in identifying investments with superior risk-reward trade-offs.
Risk Management: Helps manage risk exposure by evaluating downside risks and overall volatility, enabling more informed and strategic investment decisions.