BTC outperform atrategy### Code Description
This Pine Script™ code implements a simple trading strategy based on the relative prices of Bitcoin (BTC) on a weekly and a three-month basis. The script plots the weekly and three-month closing prices of Bitcoin on the chart and generates trading signals based on the comparison of these prices. The code can also be applied to Ethereum (ETH) with similar effectiveness.
### Explanation
1. **Inputs and Variables**:
- The user selects the trading symbol (default is "BINANCE:BTCUSDT").
- `weeklyPrice` retrieves the closing price of the selected symbol on a weekly interval.
- `monthlyPrice` retrieves the closing price of the selected symbol on a three-month interval.
2. **Plotting Data**:
- The weekly price is plotted in blue.
- The three-month price is plotted in red.
3. **Trading Conditions**:
- A long position is suggested if the weekly price is greater than the three-month price.
- A short position is suggested if the three-month price is greater than the weekly price.
4. **Strategy Execution**:
- If the long condition is met, the strategy enters a long position.
- If the short condition is met, the strategy enters a short position.
This script works equally well for Ethereum (ETH) by changing the symbol input to "BINANCE:ETHUSDT" or any other desired Ethereum trading pair.
Wyszukaj w skryptach "weekly"
time_and_sessionA library that provides utilities for working with trading sessions and time-based conditions. Functions include session checks, date range checks, day-of-week matching, and session high/low calculations for daily, weekly, monthly, and yearly timeframes. This library streamlines time-related calculations and enhances time-based strategies and indicators.
Library "time_and_session"
Provides functions for checking time and session-based conditions and retrieving session-specific high and low values.
is_session(session, timeframe, timezone)
Checks if the current time is within the specified trading session
Parameters:
session (string) : The trading session, defined using input.session()
timeframe (string) : The timeframe to use, defaults to the current chart's timeframe
timezone (string) : The timezone to use, defaults to the symbol's timezone
Returns: A boolean indicating whether the current time is within the specified trading session
is_date_range(start_time, end_time)
Checks if the current time is within a specified date range
Parameters:
start_time (int) : The start time, defined using input.time()
end_time (int) : The end time, defined using input.time()
Returns: A boolean indicating whether the current time is within the specified date range
is_day_of_week(sunday, monday, tuesday, wednesday, thursday, friday, saturday)
Checks if the current day of the week matches any of the specified days
Parameters:
sunday (bool) : A boolean indicating whether to check for Sunday
monday (bool) : A boolean indicating whether to check for Monday
tuesday (bool) : A boolean indicating whether to check for Tuesday
wednesday (bool) : A boolean indicating whether to check for Wednesday
thursday (bool) : A boolean indicating whether to check for Thursday
friday (bool) : A boolean indicating whether to check for Friday
saturday (bool) : A boolean indicating whether to check for Saturday
Returns: A boolean indicating whether the current day of the week matches any of the specified days
daily_high(source)
Returns the highest value of the specified source during the current daily session
Parameters:
source (float) : The data series to evaluate, defaults to high
Returns: The highest value during the current daily session, or na if the timeframe is not suitable
daily_low(source)
Returns the lowest value of the specified source during the current daily session
Parameters:
source (float) : The data series to evaluate, defaults to low
Returns: The lowest value during the current daily session, or na if the timeframe is not suitable
regular_session_high(source, persist)
Returns the highest value of the specified source during the current regular trading session
Parameters:
source (float) : The data series to evaluate, defaults to high
persist (bool) : A boolean indicating whether to retain the last value outside of regular market hours, defaults to true
Returns: The highest value during the current regular trading session, or na if the timeframe is not suitable
regular_session_low(source, persist)
Returns the lowest value of the specified source during the current regular trading session
Parameters:
source (float) : The data series to evaluate, defaults to low
persist (bool) : A boolean indicating whether to retain the last value outside of regular market hours, defaults to true
Returns: The lowest value during the current regular trading session, or na if the timeframe is not suitable
premarket_session_high(source, persist)
Returns the highest value of the specified source during the current premarket trading session
Parameters:
source (float) : The data series to evaluate, defaults to high
persist (bool) : A boolean indicating whether to retain the last value outside of premarket hours, defaults to true
Returns: The highest value during the current premarket trading session, or na if the timeframe is not suitable
premarket_session_low(source, persist)
Returns the lowest value of the specified source during the current premarket trading session
Parameters:
source (float) : The data series to evaluate, defaults to low
persist (bool) : A boolean indicating whether to retain the last value outside of premarket hours, defaults to true
Returns: The lowest value during the current premarket trading session, or na if the timeframe is not suitable
postmarket_session_high(source, persist)
Returns the highest value of the specified source during the current postmarket trading session
Parameters:
source (float) : The data series to evaluate, defaults to high
persist (bool) : A boolean indicating whether to retain the last value outside of postmarket hours, defaults to true
Returns: The highest value during the current postmarket trading session, or na if the timeframe is not suitable
postmarket_session_low(source, persist)
Returns the lowest value of the specified source during the current postmarket trading session
Parameters:
source (float) : The data series to evaluate, defaults to low
persist (bool) : A boolean indicating whether to retain the last value outside of postmarket hours, defaults to true
Returns: The lowest value during the current postmarket trading session, or na if the timeframe is not suitable
weekly_high(source)
Returns the highest value of the specified source during the current weekly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to high
Returns: The highest value during the current weekly session, or na if the timeframe is not suitable
weekly_low(source)
Returns the lowest value of the specified source during the current weekly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to low
Returns: The lowest value during the current weekly session, or na if the timeframe is not suitable
monthly_high(source)
Returns the highest value of the specified source during the current monthly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to high
Returns: The highest value during the current monthly session, or na if the timeframe is not suitable
monthly_low(source)
Returns the lowest value of the specified source during the current monthly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to low
Returns: The lowest value during the current monthly session, or na if the timeframe is not suitable
yearly_high(source)
Returns the highest value of the specified source during the current yearly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to high
Returns: The highest value during the current yearly session, or na if the timeframe is not suitable
yearly_low(source)
Returns the lowest value of the specified source during the current yearly session. Can fail on lower timeframes.
Parameters:
source (float) : The data series to evaluate, defaults to low
Returns: The lowest value during the current yearly session, or na if the timeframe is not suitable
Futures Auto Levels [NariCapitalTrading]Futures Auto Levels Indicator
Introduction
The "Futures Auto Levels" (FAL) indicator shows the previous day's levels, weekly open, high, low, and the Initial Balance Range (IBR).
Indicator Components
The FAL indicator comprises the following components:
Previous Day's Levels: These include the open, high, low, and close of the previous trading day. They are represented on the chart by lines and labels, helping to identify significant price levels from the prior session.
Weekly Open, High, Low: These levels represent the open, high, and low prices of the current trading week.
Initial Balance Range (IBR): The IBR is calculated based on the price range during the first 60 minutes of the trading day. It helps identify initial trading range and potential breakout levels.
How to Use the Indicator
1. Previous Day's Levels:
Monitor the previous day's open, high, low, and close to identify key support and resistance levels.
Use these levels to gauge market sentiment and potential price reversals.
2. Weekly Open, High, Low:
Pay attention to the weekly open, high, and low to understand the market's behavior within the weekly timeframe.
These levels can act as reference points for setting profit targets and stop-loss orders.
3. Initial Balance Range (IBR):
Watch for price movements within the IBR to identify potential trading opportunities.
Breakouts above or below the IBR may signal the beginning of a new trend or continuation of the current trend.
Suggested/Potential Strategies
Reversal Trading: Look for price reversals around previous day's levels, especially when they coincide with other technical indicators or significant support/resistance zones.
Trend Following: Follow the trend by trading breakouts above/below the IBR or weekly high/low levels. Use trailing stops to capture profits while the trend remains intact.
Range Trading: Trade within the IBR when the market is consolidating. Buy near the IBR low and sell near the IBR high, with tight stop-loss orders to manage risk.
Conclusion
The Futures Auto Levels indicator is designed to help incorporate levels into trading analysis and trading strategies to improve profitability and consistency.
Algoflow's Levels PlotterAlgoflow's Levels Plotter - Indicator
Release Date: Jan. 15, 2024
Release version: v3 r1
Release notes date: Jan. 15, 2024
Overview
Parses user's input of levels to be plotted and labeled on the chart for NQ & ES futures
Features
Quick plotting of predetermined price levels.
- Type or copy from another source of values in a predetermined output format.
Supports separate line plotting for Weekly, OVN and RTH values
- Plot only Weekly, OVN or RTH levels, or all
- Configure colors separately for Inflection Points, Weekly, OVN & RTH levels
- Shift/place price labels separately to easily identify levels
User Impacts of Changes
Requires users to remove previous version and re-add indicator "Algoflow's Levels Plotter", then re-add values. Colors and shift values will need to be re-entered and/or reconfigured
Support
Questions, feedbacks, and requests are welcomed. Please feel free to use Comments or direct private message via TradingView.
Quick usage notes:
The indicator allows you to enter data for both ES & NQ at the same time. This is useful in single chart window/layout situations, like viewing on the phone. When you switch between futures, the data is already there.
If you leave the entries blank, nothing will be plotted. This is useful if you want to have separate charts for ES & NQ. So you can just enter only the relevant data of either.
As an indicator, input values are saved within it, until it is removed from the chart. Input for one chart will not update other charts of the same ticker, even in the same layout.
The easiest and quickest way to share the inputs across all charts and layouts is to use the Indicator Templates feature.
- After input values are entered (for both ES & NQ futures) via the indicator's Settings, select ""Save as Default"".
- Click on ""Indicator Templates"" (4 squares icon), and click on ""Save Indicator template...""
- Remove the previous version of the indicator in other charts.
- Click on ""Indicator Templates"" icon, and select the newly created template. Repeat this for other charts of the same futures ticker
The labels can be disabled in settings > Style tab. Use the Inputs tab to configure orientation (left or right of current bar on chart), and how much spacing from the current (in distance of bars)
Format example:
Primary directional inflection point: 1234
For Bulls: 1244.25, 1254, 1264.50
For Bears: 1224, 1214, 1204
Changes
v3 r1 - Fixed erroneous default values in Weekly input sections. Added options to en/disable display of each set (session) of levels. Default label text size to normal, from small.
- Jan 15, 2024
v2 r9 - Added support for USTEC & US500.
- Dec. 10, 2023
v2 r8 - Added configuration features for users to modify the labels' text colors and size. Simplified code further by moving inputs processing modules into a single user function.
- Oct. 31, 2023
v2 r7 - Added support for the micro NQ & ES. Modified to ignore string case in inputs
- Oct 18, 2023
v2 r4 - Added support of weekly lines and labels features. Began the process of optimizing/simplifying code
- Oct. 15, 2023
v2 r3 - Made Inflection Point levels' colors configurable
- Oct. 04, 2023
v2 r2 - Removed comments & debug codes from development build revision #518
- Oct. 04, 2023
v2 r1 - Released from development revision #518. Major rewrite to fix previous and overlapping plots of lines and labels.
- Oct. 04, 2023
v1 r2 - First release of indicator
- Oct. 02, 2023
Sunday Vertical Lines (00:00 NY)Short Description:
Experience enhanced chart clarity with our "Sunday Midnight Vertical Lines" indicator. This tool elegantly marks every Sunday at 00:00 New York time, providing traders with a clear reference point for weekly market resets and potential strategy adjustments.
Detailed Description:
Purpose:
The "Sunday Midnight Vertical Lines" indicator is designed to help traders and market analysts visually segment their charts based on weeks. By clearly demarcating the start of each trading week, this tool aids in performing weekly analyses, understanding market rhythms, and preparing for the week ahead.
Key Features:
Automatic Time Zone Adjustment: The indicator adjusts for New York time, ensuring accuracy regardless of the user's local time zone.
Visual Clarity: Draws a distinct red vertical line at 00:00 each Sunday, offering a stark contrast against typical chart elements.
Performance Optimized: Efficiently coded to maintain chart performance, even on data-rich interfaces.
User-Friendly: No complex settings required. The tool works immediately upon addition to the chart, facilitating ease of use for traders of all skill levels.
Use Cases:
Weekly Market Analysis: Ideal for traders who conduct weekly market reviews, as it visually segments the chart at the beginning of each trading week.
Strategic Planning: Useful for planning and adjusting weekly trading strategies.
Historical Reference: Assists in historical market analysis by providing clear reference points for the start of each week.
Conclusion:
Whether you're a day trader, swing trader, or long-term investor, the "Sunday Midnight Vertical Lines" indicator is a simple yet powerful tool to enhance your chart analysis. It offers a clear, visual reference point for the start of each trading week, aiding in strategy development and market understanding.
[KenStrat] - Catching trend for the PipsDescription:
The " - Catching trend for the Pips" indicator is designed to help traders identify potential trend reversal points and capture significant price movements, with a focus on both daily and weekly perspectives.
**Friday Close Analysis:**
This component of the indicator concentrates on the Friday close of each week. The script displays visual elements on the daily chart exclusively. Specifically, it marks key price levels, providing insights into the closing position relative to the week's range. The indicator categorizes the closing price into three zones: above 66%, between 33% and 66%, and below 33%. This distinction aids traders in assessing the strength and directionality of the market at the end of the week. The displayed label offers a concise summary of the Friday's closing behavior, aiding in quick trend analysis.
**Weekly Trend Verification:**
The second part of the indicator focuses on verifying the weekly trend. By identifying the highest highs and lowest lows of the past two weeks, the script determines whether the current price action exhibits a bullish or bearish trend. The visualization on the chart helps traders assess the broader trend direction and make informed decisions based on the prevailing market sentiment. The label dynamically updates to indicate whether the overall trend is bullish, bearish, or neutral.
**Key Features:**
- Differentiates between Friday closing price zones for trend assessment.
- Weekly trend verification based on highest highs and lowest lows.
- Visual representation of trend conditions on the chart.
- Dynamic labels for quick interpretation of trend strength and direction.
- Exclusively designed for daily and weekly timeframes.
The " - Catching trend for the Pips" indicator provides a comprehensive tool for traders seeking to capture and analyze trend movements efficiently, allowing for informed decision-making in the dynamic Forex market.
ICT True Day Range [MK]The indicator displays the following:
Vertical line day separator from 00:00 to 00:00 EST
High/Low lines for the days true range from 00:00 to EOD
Opening line from 00:00 EST to EOD
Opening line from 08:30 EST to EOD
Weekly Opening line from Sunday open at 18:00 EST to last bar in the week
Monday range high/low/mid line, which can be extended to EOW
Text displaying Days of the Week
All functions can be fully customized regarding color/style and line width.
Below shows image of indicator with day separator: (it didn't show on the main chart despite being enabled?)
All of the above are to be used to give the user all the tools necessary to analyze the following concepts which can be studied on ICTs you tube channel:
Weekly profile, eg, has the weekly manipulated below the weekly open to then rise the rest of the week?
Daily profile, eg, has the day manipulated below the daily open (00:00 EST) to then rise the rest of the day?
Daily liquidity grab, eg has the current day taken PDH/PDL at the start of the current day?
Daily targets, eg will the current day end up taking liquidity from the PDH/PDL?
Monday range, will Mondays high/low range act as the accumulation phase of the weekly AMD profile?
Tuesday/Wednesday/Thursday/Friday reversal, eg, does a day of the week line up with a HTF target and a high volatility news event which could see price reverse after the manipulation phase of the weekly AMD profile?
In strong trending markets, will the 0830 open line be used in the NY session as manipulation reference in the same manner as the 00:00 line is normally used?
The above examples of how the indicator 'could' be used are not the only ways to use the indicator.
The indicator is by no means a trading strategy on its own. Users should be fully aware of ICT concepts and have performed extensive back-testing before using the indicator with live accounts.
RVol LabelThis Code is update version of Code Provided by @ssbukam, Here is Link to his original Code and review the Description
Below is Original Description
1. When chart resolution is Daily or Intraday (D, 4H, 1H, 5min, etc), Relative Volume shows value based on DAILY. RVol is measured on daily basis to compare past N number of days.
2. When resolution is changed to Weekly or Monthly, then Relative Volume shows corresponding value. i.e. Weekly shows weekly relative volume of this week compared to past 'N' weeks. Likewise for Monthly. You would see change in label name. Like, Weekly chart shows W_RVol (Weekly Relative Volume). Likewise, Daily & Intraday shows D_RVol. Monthly shows M_RVol (Monthly Relative Volume).
3. Added a plot (by default hidden) for this specific reason: When you move the cursor to focus specific candle, then Indicator Value displays relative volume of that specific candle. This applies to Intraday as well. So if you're in 1HR chart and move the cursor to a specific candle, Indicator Value shows relative volume for that specific candlestick bar.
4. Updating the script so that text size and location can be customized.
Changes to Updated Label by me
1. Added Today's Volume to the Label
2. Added Total Average Volume to the Label
3. Comparison vs Both in Single Line and showing how much volume has traded vs the average volume for that time of the day
4. Aesthetic Look of the Label
How to Use Relative Volume for Trading
Using Relative Volume (RVol) in trading can be a valuable tool to help you identify potential trading opportunities and gain insight into market behavior. Here are some ways to use RVol in your trading strategy:
Identifying High-Volume Breakouts: RVol can help you spot potential breakouts when the volume surges significantly above its average. High RVol during a breakout suggests strong market interest, increasing the probability of a sustained move in the direction of the breakout.
Confirming Trends and Reversals: RVol can act as a confirmation tool for trends and reversals. A trend accompanied by rising RVol indicates a strong and sustainable move. Conversely, a trend with declining RVol might suggest a weakening trend or potential reversal.
Spotting Volume Divergence: When the price is moving in one direction, but RVol is declining or not confirming the move, it may indicate a divergence. This discrepancy could suggest a potential reversal or trend change.
Support and Resistance Confirmation: High RVol near key support or resistance levels can indicate potential price reactions at those levels. This confirmation can be valuable in determining whether a level is likely to hold or break.
Filtering Trade Signals: Incorporate RVol into your existing trading strategy as a filter. For example, you might consider taking trades only if RVol is above a certain threshold, ensuring that you focus on high-impact trading opportunities.
Avoiding Low-Volume Traps: Low RVol can indicate a lack of interest or participation in the market. In such situations, price movements may be erratic and less reliable, so it's often wise to avoid trading during low RVol periods.
Monitoring News Events: Around significant news events or earnings releases, RVol can help you gauge the market's reaction to the information. High RVol during such events can present trading opportunities but be cautious of increased volatility and potential gaps.
Adjusting Trade Size: During periods of extremely high RVol, it might be prudent to adjust your position size to account for higher risk.
Using Relative Volume in Morning Session
If the Volume traded in first 15 minute to 30 Minutes is already at 50% or 100% depending upon the ticker, it means that it is going to have very high Volume vs average by end of the day.
This gives me conviction for Long or Short Trades
Remember that RVol is not a standalone indicator; it works best when used in conjunction with other technical and fundamental analysis tools. Additionally, RVol's effectiveness may vary across different markets and trading strategies. Therefore, backtesting and validating the use of RVol in your trading approach is essential.
Lastly, risk management is crucial in trading. While RVol can provide valuable insights, it cannot guarantee profitable trades. Always use appropriate risk management strategies, such as setting stop-loss levels, and avoid overexposing yourself to the market based solely on RVol readings.
ICT HTF Liquidity Levels /w Alert [MsF]Japanese below / 日本語説明は英文の後にあります。
-------------------------
*This indicator is based on sbtnc's "HTF Liquidity Levels". It's a very cool indicator. thank you.
It has 3 functions: visualization of HTF liquidity (with alert), candle color change when displacement occurs, and MSB (market structure break) line display.
=== Function description ===
1. HTF liquidity (with alert)
Lines visualize the liquidity pools on the HTF bars. Alerts can be set for each TF's line.
Once the price reaches the line, the line is repaint.
To put it plainly, the old line disappears and a new line appears. The line that disappeared remains as a purged line. (It is also possible to hide the purged line with a parameter)
The alert will be triggered at the moment the line disappears. An alert will be issued when you touch the HTF's liquid pools where the loss is accumulated, so you can notice the stop hunting with the alert.
This alert is an original feature of this indicator.
The timeframe of the HTF can't modify. You can get Monthly, weekly, daily and H1 and H4.
Each timeframe displays the 3 most recent lines. By narrowing it down to 3, it is devised to make it easier to see visually. (This indicator original)
2. Displacement
Change the color display of the candlesticks when a bullish candle stick or bearish candle stick is attached. Furthermore, by enabling the "Require FVG" option, you can easily discover the FVG (Fair Value Gap). It is a very useful function for ICT trading.
3. MSB (market structure break)
Displays High/Low lines for the period specified by the parameter. It is useful for discovering BoS & CHoCH/MSS, which are important in ICT trading.
=== Parameter description ===
- HTF LIQUIDITY
- Daily … Daily line display settings (color, line width)
- Weekly … Weekly line display settings (color, line width)
- Monthly … Monthly line display settings (color, line width)
- INTRADAY LIQUIDITY
- 1H … 1H line display settings (color, line width)
- 4H … 4H line display settings (color, line width)
- PURGED LIQUIDITY … Display setting of the line once the candle reaches
- Show Purge Daily … Daily purged line display/non-display setting
- Show Purge Weekly … Weekly purged line display/non-display setting
- Show Purge Monthly … Monthly purged line display/non-display setting
- Show Purge 1H … 1H purged line display/non-display setting
- Show Purge 4H … 4H purged line display/non-display setting
- MARKET STRUCTURE BREAK - MBS
- Loopback … Period for searching High/Low
- DISPLACEMENT FOR FVG
- Require FVG … Draw only when FVG occurs
- Displacement Type … Displacement from open to close? or from high to low?
- Displacement Length … Period over which to calculate the standard deviation
- Displacement Strength … The larger the number, the stronger the displacement detected
-------------------------
このインジケータはsbtncさんの"HTF Liquidity Levels"をベースに作成しています。
上位足流動性の可視化(アラート付き)、変位発生時のローソク色変更、MSB(market structure break)ライン表示の3つの機能を有します。
<機能説明>
■上位足流動性の可視化
上位足の流動性の吹き溜まり(ストップが溜まっているところ)をラインで可視化します。ラインにはアラートを設定することが可能です。
一度価格がラインに到達するとそのラインは再描画されます。
平たく言うと、今までのラインが消えて新しいラインが出現する。という事です。
消えたラインはpurgeラインとして残ります。(パラメータでpurgeラインを非表示にすることも可能です)
アラートはラインが消える瞬間に発報します。上位足の損切り溜まってるところにタッチするとアラートを発報するので、アラートにてストップ狩りに気づくことができます。
このアラート発報については本インジケータオリジナルの機能となります。
表示可能な上位足のタイムフレームは固定です。月足、週足、日足およびH1とH4を表示することができます。
各タイムフレーム、直近から3つのラインを表示します。3つに絞ることで視覚的に見やすく工夫しています。(本インジケータオリジナル)
■変位発生時のローソク色変更
大きな陽線、陰線を付けた場合に、そのローソク足をカラー表示を変更します。
さらに"Require FVG"オプションを有効にすることで、FVG(Fair Value Gap)を容易に発見することができます。ICTトレードにを行うにあたり大変有用な機能となっています。
■MSB(market structure break)ライン表示
パラメータで指定した期間のHigh/Lowをライン表示します。ICTトレードで重要視しているBoS & CHoCH/MSSの発見に役立ちます。
<パラメータ説明>
- HTF LIQUIDITY
- Daily … 日足ライン表示設定(色、線幅)
- Weekly … 週足ライン表示設定(色、線幅)
- Monthly … 月足ライン表示設定(色、線幅)
- INTRADAY LIQUIDITY
- 1H … 1時間足ライン表示設定(色、線幅)
- 4H … 4時間足ライン表示設定(色、線幅)
- PURGED LIQUIDITY … 一度到達したラインの表示設定
- Show Purge Daily … 日足ライン表示/非表示設定
- Show Purge Weekly … 週足ライン表示/非表示設定
- Show Purge Monthly … 月足ライン表示/非表示設定
- Show Purge 1H … 1時間足ライン表示/非表示設定
- Show Purge 4H … 4時間足ライン表示/非表示設定
- MARKET STRUCTURE BREAK - MBS
- Loopback … High/Lowを探索する期間
- DISPLACEMENT FOR FVG
- Require FVG … FVG発生時のみ描画する
- Displacement Type … openからcloseまでの変位か?highからlowまでの変位か?
- Displacement Length … 標準偏差を計算する期間
- Displacement Strength … 変位の強さ(数字が大きいほど強い変位を検出)
Higher Time Frame Average True RangesPurpose: This script will help an options trader asses risk and determine good entry and exit strategies
Background Information: The true range is the greatest of: current high minus the current low; the absolute value of the current high minus the previous close; and the absolute value of the current low minus the previous close. The Average True Range (ATR) is a 14-day moving average of the true range. Traders use the ATR indicator to assess volatility in stocks and decide when to enter and exit trades. It is important to note the limitations of using True Range and ATR: These indications cannot tell you the direction of your options trade (call vs. put) and they cannot tell you whether a particular trend is about to reverse. However, it can be used to assess if volatility has peaked for a particular direction and time period.
How this script works: This indicator calculates true range for the daily (DTR), weekly (WTR), and monthly (MTR) time frames and compares it to the Average True Range (ATR) for each of those time frames (DATR, WATR, and MATR). The comparison is displayed into a colored table in the upper right-hand corner of the screen. When a daily, weekly, or monthly true range reaches 80% of its respective ATR, the row for that time frame will turn Orange indicating medium risk for staying in the trade. If the true range goes above 100% of the respective ATR, then the row will turn Red indicating high risk for staying in the trade. When the row for a time period turns red, volatility for the time period has likely peaked and traders should heavily consider taking profits. It is important to note these calculations start at different times for each time frame: Daily (Today’s Open), Weekly (Monday’s Open), Monthly (First of the Month’s Open). This means if it’s the 15th of the month then the Monthly True Range is being calculated for the trading days in the first half of the month (approximately 10 trade days).
The script also plots three sets of horizontal dotted lines to visually represent the ATR for each time period. Each set is generated by adding and subtracting the daily, weekly, and monthly ATRs from that time periods open price. For example, the weekly ATR is added and subtracted from Mondays open price to visually represent the true range for that week. The DATR is represented by red lines, the WATR is represented by the green lines, and the MATR is represented by the blue lines. These plots could also be used to assess risk as well.
How to use this script: Use the table to assess risk and determine potential exit strategies (Green=Low Risk, Orange=Medium Risk, Red=High Risk. Use the dotted lines to speculate what a stock’s price could be in a given time period (Daily=Red, Weekly=Green, and Monthly=Blue). And don’t forget the true range’s calculation and plots starts at the beginning of each time period!
Invest-Long : Script for quick checks before investingA simple script to verify RSI, SMAs, VWMA, and Pivots on Daily, Weekly, and Monthly time frames.
In case if you are not interested in SMA's or want to add different cheks -- simply copy the script to local and edit.
Happy investing.
Add the script to any chart and table values remain the same irrespective of current chart resolution, as it checks on Daily, Weekly, and Monthly time frames.
The table has multiple columns.
1st column checks on RSI value on all 3 timeframes. Ideally, look for all green and D>W>M
2nd Column: Check current Close is above 20 SMA and 50 SMA on Daily / Weekly / Monthly time frames
3rd Column: Check SMA 13> SMA 34, SMA 34 > SMA 55 and SMA 20 > SMA 50 on Daily / Weekly time frames
4th Column: Check Current close is above Weekly Pivot and Monthly Pivot. And also verify Close is above 4 Week High.
5th Column: Verify Close is above Daily VWMA. Also Daily VWMA is > Weekly VWMA and Weekly > Monthly.
// Similarly you can add more checks based on different time frames
Feel free to trouble me incase if need help.
VWAP + EMA Analysis [Joshlo]Overview and Use Case
VWAP Analysis gives the possibility to combine multiple time frames of VWAP along with a triplet of exponential moving averages. This can provide insight into potential scalp, swing and longer term trades, depending on your time frame. The use of this indicator with it's setup is based off the the Scalp Setup Alerts provided by Roensch Capital.
The primary use for this script is to help with intraday scalp set ups. Using the Daily VWAP, turned on by default, we can look for price to respect and bounce from one of the VWAP lines (support or resistance) back toward equilibrium, we can also look for price to bounce off of equilibrium and move back toward VWAP support or resistance.
The chart attached shows AMD bouncing off of the Daily time frame VWAP Resistance level multiple times (see yellow boxes), often with confirmation given by an increase in volume which is often far higher than the average volume. In many of these cases a short position could've been opened or put option could have been placed with a profitable outcome.
Every line projected onto the chart via this indicator has the potential to create support or resistance as well as causing 'hang ups', meaning price loses it's momentum, slows down and hangs out in the particular area. This is shown on the chart within the green box.
Chart walkthrough - See attached chart
After a rejection off of the Daily VWAP Resistance line (depicted by the white circle), price starts to move back toward Daily VWAP Equilibrium. In order to reach this line, price needs to move through the 20EMA (white) and 50EMA (purple), the Weekly VWAP Resistance (red circles) and the 200EMA (orange). All of these lines are a part of this single indicator.
The 20EMA seems to offer little resistance but follows the price on it's move, offering some resistance to a volatile move upward. Initially upon contact with the 50EMA, price hangs up and bounces above and below the line whilst finding support on the Weekly VWAP Resistance at the same time. This causes a 'hang up' or sideways movement for around 20 minutes of trading. A potential trade may have entered at the white circle with a VWAP Resistance rejection and exited upon contact with the 50EMA in anticipation of multiple EMAs and support / resistance lines converging which is known to cause price movement to slow.
Eventually with an increase in volume, price breaks below the 20EMA (white), 50EMA (purple) and the Weekly VWAP Resistance level (red circles). Price then finds support on the 200EMA (orange), although there was potential for the price to fall to the Daily VWAP Equilibrium (solid blue). As the Red VWAP lines tend to act more often as resistance as opposed to support (price is rarely above these lines for extended periods), the trade from earlier may have profited more by awaiting contact with the 200EMA before exiting, taking the assumption that the Weekly VWAP Resistance was more likely to act as resistance than support.
A period of consolidation in the green box, around the Weekly VWAP Resistance, 20EMA, 50EMA and with support from the 200EMA eventually resulted in another break out where the price came back up to the Daily VWAP Resistance. Prior to the end of this trading day, there were two more opportunities for scalp setups based off of the price showing consistent rejections off the Daily VWAP Resistance back down to the 50EMA.
In the final example, price breaks above the Daily VWAP Resistance but quickly rejects off of the Monthly VWAP Resistance. For examples where the VWAP Resistance or Support or broken, it can help to look at an indicator such as the RSI to look for bullish divergence or bearish divergence.
Just as this example shows bounces and rejection off of VWAP Resistance, the same applies around the Equilibrium and Support VWAP lines.
The perfect scenario would be to find a ticker where there has already been two or three bounces off of one of these levels, with the goal of taking the trade on the next bounce and either using a percentage price target or technical price target based off of the EMAs or VWAP lines. If there are EMAs close in the direction you want to take the trade, there is a higher chance of hang ups and reversals, so a clear run is the more desired trade set up.
You can also look for these indicator lines to stack up in order to form a stronger support and resistance. For example the 200EMA and Daily VWAP Equilibrium being close to each other may suggest it would take more of an effort to break both of these levels, but one by itself may break more easily.
Indicator Setup
In the settings for the indicator, almost everything you might want to change can be done from the Input tab.
The three options for VWAP (daily, weekly and monthly) allow for analysis on multiple time frames. Daily is turned on as standard.
Standard Deviation Multiplier is set to 2 as standard, this effects the distance of the VWAP support and resistance from the equilibrium line. This seems to be a level that works well with finding support and resistance lines, however if there is excessively high or low volume, occasionally the lines can be thrown off. You can adjust this level if required to find a 'sweet spot' where price likes to reject or find support.
The colors for all VWAPs can be adjusted via the Inputs tab, however if you'd like to change the type of line these are depicted as, this can be done from the Styles tab.
The 3 EMAs (20, 50 and 200) can be toggled on or off and also have their color changed. The style of the lines can be adjusted from with the Styles tab if required.
[CP]Pivot Boss Multi Timeframe CPR Inception with MACD and EMAINTRODUCTION:
This indicator combines multi-timeframe CPR bands with MACD Momentum and EMA trend, all projected on the candlestick chart through a novel visualization.
If you have seen my other indicators on TradingView, you would know that I use floor pivots a lot and “Secrets of a Pivot Boss” is my favorite book. While using floor pivots, time and again I have noticed an interesting price behavior,
Trending moves in price typically start from around the Central Pivot Range (CPR). The CPR could be from ANY timeframe. These moves can easily be caught using simple momentum and trend indicators like MACD and EMA crossovers.
Yes, it is that simple. Follow along to understand how to use this indicator.
INDICATOR SETTINGS:
RANGEBOUND MACD AND EMA MARKINGS:
TradingView limits the max number of labels that can be shown on a chart to 500. Therefore, if you go far back enough, you won't see any markings for the MACD or EMA setups. If you are looking to test the efficacy of this indicator in the past, change the start and end dates to your desired timeframe and then select the ‘Mark MACD and EMA Setups in Range?’ option.
MULTI TIMEFRAME CENTRAL PIVOT RANGE:
Here you can select CPRs and their bands from which timeframes are shown on the chart. I will share my favorite settings later in this description.
CPR CONFIGURATION:
Show CPR Labels: CPRs markings can carry labels, so that you don’t confuse between which line is what. Use this setting to toggle them On/Off.
Show Next Time Period Pivots: Check this option if you want to see the CPR of the next time period. This is typically done to figure out the ’Two Day CPR Relationship’ . Read the book, “Secrets of a Pivot Boss”, to understand more.
EMA TREND:
Show EMA on the Chart: EMAs will be plotted on the chart. Standard stuff.
Mark EMA Crossovers on Chart: EMA crossovers will be marked on the chart in diamond shapes. If you are using EMA crossovers, I recommend setting this option to True.
Rest of the EMA settings are fairly obvious.
MACD MOMENTUM:
Projecting MACD parameters directly on the candlesticks is surely going to give you a new perspective about price action and MACD.
Also, in order to better understand the MACD projections on the chart, you can add a standard MACD indicator on the chart with default settings to figure out what my indicator is actually showing you.
Marking MACD Crossovers on Chart: Marks the MACD signal crossovers on the chart. This visualization was a game changer for me.
Show MACD Histogram on Chart: Projects the complete MACD Histogram in a novel fashion (Try it!). You will be able to visually see the ebbs and flow of momentum in the charts.
Mark MACD Histogram Peaks on Chart: Marks only the MACD peaks instead of the complete histogram. Peaks are a great way to enter an ongoing trend and to play an intraday rangebound market.
Rest of the settings are just the standard settings that you will find in a typical MACD indicator.
ALERTS:
Not shown in the settings panel, but I have added alerts for EMA and MACD Crossovers so that you don’t have to sit in front of the charts or constantly check the price all day long.
If you don’t know how to set alerts in TradingView, then please Google it.
INDICATOR USAGE EXAMPLES:
This indicator can be used in intraday as well as in higher timeframes.
There are quite a few variations possible, I personally prefer to use the EMA crossovers in intraday (5m) and MACD on Daily timeframes.
This is just a matter of personal preference, some people might prefer using EMAs only or MACD only in all timeframes.
Here are my personal settings for the intraday 5-minute timeframe:
Turn on all the CPR pivots starting from Yearly all the way to Daily. You can turn on 6 hourly and 4 hourly as well if you want.
Hourly CPR is mostly used when the price is in a strong trend and you missed the entry and don’t know when to enter. Price will typically experience pullbacks towards the Hourly CPR, before resuming in the direction of the trend. That is your chance to hop onto the bandwagon.
For Intraday, I keep the Bands off. Just a personal preference here.
You can turn ON the Show CPR Labels , if you want.
Turn ON both the options in the EMA TREND section. You would want to see the EMA crossovers marked on the chart as well as the EMAs themselves, as the distance between the two EMAs will give you an idea about the strength of the trend.
Keep rest of the settings in the EMA section as default (you can change the colors if you wish). I keep the same EMAs as the ones kept in the MACD indicator. I like to keep things simple.
In the MACD MOMENTUM section, turn ON Mark MACD Histogram Peaks on Chart and all the other options turned OFF. Leave the other settings as default. By the way, these are the default settings of the standard MACD Indicator.
You can set up EMA Bullcross and Bearcross alarms if you like.
Before checking out the examples, remember one super simple rule:
SOME OF THE BEST TRENDING MOVES IN THE MARKET, BE IT INTRADAY OR OTHERWISE, ORIGINATE IN THE VICINITY OF A LARGER TIMEFRAME PIVOT/CPR.
Look for price settling above/below a pivot, and then a move away from the pivot in any direction is typically a trending move.
You can use hourly pivots or MACD Histogram peaks marked on the chart to enter an existing trend, or add to your positions.
Let’s have a look at a few recent intraday examples from the Crypto, Indian, and US equity markets.
I have added my comments in the charts to make you easily understand what is going on.
Understand that both, moving average crossover and MACD, will give out a lot of signals (chop) every day. But almost 70% of them are going to be fake signals. It is the signals that you get when the price is near a Pivot, that tend to convert into gorgeous trending moves that last.
BTC 5m Charts
NIFTY Futures 5m Charts (good intraday trends are hard to find here, as the market is very efficient)
TSLA 5m Charts
Some important points for using this indicator in higher timeframes:
For higher timeframes, my personal preference is to go with the MACD indicator. I personally find MACD to be lethal on daily and weekly timeframes, if you know how to use it well.
The default settings of the indicator are the settings I use for both, Daily and Weekly, timeframes. Additionally, I turn off the CPR labels.
In theory large trending moves still have a big probability to start near an important pivot level, however, in larger timeframes, trending moves can start from anywhere. They need not start in the vicinity of any important pivot (but they often do!).
Weekly pivots can act as great pullback levels when the price is in strong momentum, when trading on the daily timeframe.
Quarterly Pivots act as great pullback levels when the price is in strong momentum, when trading on the weekly timeframe.
BTC Weekly Chart
BTC Daily Chart
Nifty Weekly Chart
Nifty Daily Chart
NASDAQ Weekly Chart
NASDAQ Daily Chart
FINAL WORDS:
Please understand that I have Cherry Picked the examples to showcase the capability of the indicator and its usage.
DO NOT conflate the accuracy of examples with the accuracy of this indicator.
Biggest catch is the fact that this indicator, like every other indicator out there, will have whipsaws. Some I have also marked in the example charts.
You need to come up with your own technique to avoid whipsaws, one technique I have shared here…… big moves typically start near pivots.
Work on avoiding whipsaws and finding you own edge in the markets.
If you really want to learn how to use Pivots, read the book ’Secrets of a Pivot Boss’ . This book can change your life.
My:HTF O/H/L/C█ MY Higher Time Frame Open / High / Low / Close
This indicator shows one line per Higher Time Frame Price of Interest.
We are interested to know whether we are currently seeing support or resistance at previous daily / weekly / monthly price of interest.
Each price of interest can be displayed or hidden in the configuration. Each line has a label attached to it with the (short) label on it to help identifying what is this line.
Price of interest with (short) label :
Current Daily Open (CDO)
Current Daily High (CDH)
Current Daily Low (CDL)
Previous Daily Open (PDO)
Previous Daily High (PDH)
Previous Daily Low (PDL)
Previous Daily Close (PDC)
Current Weekly Open (CWO)
Current Weekly High (CWH)
Current Weekly Low (CWL)
Previous Weekly Open (PWO)
Previous Weekly High (PWH)
Previous Weekly Low (PWL)
Previous Weekly Close (PWC)
Current Monthly Open (CMO)
Current Monthly High (CMH)
Current Monthly Low (CML)
Previous Monthly Open (PMO)
Previous Monthly High (PMH)
Previous Monthly Low (PML)
Previous Monthly Close (PMC)
RVC-Trade-With-Pivot-LevelsHow to Use PIVOT Levels for Trading
Always remember ->: *Trade with trend*
About script:
1. Daily and Weekly close above Pivot Level.
-- Sentiment is highly positive. Pivot Level acts as strong support.
2. Daily Close above Pivot and Weekly Close Below Pivot
-- Sentiment is positive.Weekly Pivot Level may act as strong resistance.
3. Daily close below Pivot and weekly close above Pivot
-- Sentiment is negative but weekly Pivot Level can acts as strong support.
4. Daily and Weekly Close below Pivot Level
-- Sentiment is highly Negative. Pivot Level acts as strong resistance.
BUY/SELL -- ENTRY
BUY ABOVE 23.6% UPWARD
IF Trend is positive and price cross and sustains above 23.6%(R1) upside, then it will be entry from BUY perspective.
If R1 is entry, R2/R3/R4/R5 ... will be targets.
SELL Below 23.6% Downward
IF Trend is negative and price cross and sustains below 23.6%(S1) downside, then it will be entry from SELL perspective.
If S1 is Sell side entry, S2/S3/S4/S5 will be targets.
Before taking ENTRY on BUY or SELL Side, please know your risk levels, Stop Loss and trade EXECUTION process.
Finally:
My view is my view and remains with me only. Once you accept it and trade it, it becomes your view. So credit or blame all yours.:)
Double RSIThis is double RSI script which plots one time frame higher RSI along with the current time frame i.e
For Weekly chart it display Weekly and Monthly RSI
For Daily chart it display Daily and Weekly RSI
For Intraday chart it display Intraday and Daily RSI.
Usage:
If Daily RSI is above 60 and weekly above 40 and moving up then stock is in a good uptrend look for buying when Daily takes support at 60. Usually First test of Daily produces a good entry for subsequent entries probability decreases.
For Downtrend look for Daily RSI below 40 and weekly below 60.
Volumeweighted macd leader with bb squeezethis indicator is very useful for stocks or crytpto especialy 3d and weekly charts
daily shows good too but if u re a daily trader use it if not dont use it coz 4h and daily is noisy some when there is no trend
thats why weekly and 3d is good because it ll give u accurate signal and trend reversals
this is not my script just a combination of lazybear squeeze momentum, macdleader and volume weighted macd of kivanc
i merge them so it also shows bb squeeze on zero line and settings name is median
macd leader is 2 differen color above zero line and below zero line
above zero line if macd leader is green its buy signal and trend is up
if blue it meand no trend or trend reversal so sell or wait if u use 4h or daily but 3d and weekly it means sell
below zero line macd leader color is red and means that there is downtrend and do not buy
when 3d or weekly turns blue on macd leader it means trend reversal about the start
good with heiken ashi candles
DO NOT FORGET THIS IS NOT PERFECT INDICATOR FOR SHORT TERM, PREFER IT 3D AND WEEKLY FR BETTER RESULTS
[CT] D&W PPO + RBF + DivergenceThis indicator combines two separate ideas into one tool so you can read trend context from your price chart while timing momentum shifts from a clean oscillator panel. The first component is the Daily and Weekly Percentage Price Oscillator (D&W PPO), which measures the relationship between two EMA spreads that are intentionally built to reflect two “speeds” of market structure. The “weekly” leg is calculated as the percentage distance between a slower and faster EMA pair (L1 and L2), and the “daily” leg is calculated as the percentage distance between a shorter EMA pair (L3 and L4), but both are normalized by the same long EMA (e2) so the values behave like a percent-based oscillator rather than raw points. The script then combines those two legs by creating R = W + D, and it plots the histogram as R − W, which simplifies to D. That is not a mistake, it is the point of the design. By setting the baseline at “R equals W,” the zero line becomes a very intuitive threshold that tells you whether the shorter-term push is adding to the longer-term bias or subtracting from it. When the histogram is above zero, the daily component is supportive of the larger trend pressure, and when it is below zero, the daily component is opposing it. The histogram color is intentionally binary and stable, green when the histogram is at or above zero and red when it is below, so the panel reads like a momentum confirmation tool rather than a noisy oscillator that constantly shifts shades.
The second component is the RBF Price Trail, which is drawn on the upper price chart even though the indicator itself lives in a lower panel. This line is not a moving average in the traditional sense. It is a Radial Basis Function kernel smoother that weights recent prices based on their similarity rather than only their recency. In plain terms, the kernel attempts to build a smoother “baseline” that adapts to the shape of price action, and then the script optionally wraps that baseline inside an ATR band and applies a Supertrend-like trailing clamp. When the ATR band is enabled, the line will not simply track the kernel value, it will trail price and hold its position until price forces it to ratchet. This behavior is what makes it useful as a structure-aligned trend line rather than just another smoothing curve. When the adaptive band boost is enabled, the band width is multiplied by a factor that grows when recent price change is large relative to a lookback normalization window. That means the trailing mechanism can adapt to fast markets by changing the effective band behavior, which helps reduce whipsaws in choppy conditions while still allowing the line to respond when volatility expands. The line color is determined by where price closes relative to the trail, bullish when price is above the trail and bearish when price is below it, and you can optionally color your actual chart candles from either the PPO state or the RBF state depending on what you want your eyes to follow.
The settings are organized so you can control each module without changing how the core PPO trend logic behaves. The PPO settings L1, L2, L3, and L4 define the EMA lengths used to compute the weekly leg W and the daily leg D. Increasing these values makes the oscillator slower and smoother, while decreasing them makes it react faster to recent movement. “Show W line” is simply a visual aid, it plots the W line in the oscillator panel so you can see the longer-term component, but it does not change the histogram logic. “Histogram thickness” is purely visual and controls how thick the column bars are. The PPO colors are the two base colors used for the histogram state, green when the daily component is supportive and red when it is opposing.
The RBF settings control what you see on the upper chart. “Show RBF on Price Chart” turns the trail line on or off. “Source” chooses which price series feeds the kernel, and close is usually the cleanest choice. “Kernel Length” determines how many bars the kernel uses; a larger value makes the baseline smoother and slower, and a smaller value makes it more reactive. “Gamma Adj” controls how quickly the kernel’s weights decay as price becomes dissimilar, so higher gamma tends to make the kernel react more sharply to changes while lower gamma produces a broader smoothing effect. “Use ATR Trail Band” is the switch that turns the kernel baseline into a trailing band line, and it is the reason the line can “hold” and then ratchet instead of moving continuously like a normal moving average. “ATR Length” and “ATR Factor” control the width of that band, and widening the band will generally reduce flips and noise at the cost of later signals. “Use Adaptive Band Boost” turns on the volatility normalization idea, “Boost Normalization Lookback” defines how far back the script looks to determine what counts as a large price change, and “Boost Multiplier” controls how strongly the band behavior is adjusted during those periods. The line width and bull/bear colors are visual controls only.
Price bar coloring is intentionally handled with a single selector so you do not end up with two modules fighting to color candles differently. If you choose “Off,” nothing on the main chart is recolored. If you choose “PPO,” your price candles reflect whether the PPO histogram is above or below zero. If you choose “RBF,” your price candles reflect whether price is above or below the RBF trail. Most traders will pick one and stick with it so the chart communicates a single bias at a glance.
The divergence module is optional and is designed to be a confirmation layer rather than a primary trigger. When enabled, it can mark regular divergence and hidden divergence, and it lets you decide what the pivots should be based on. The divergence source can be the PPO histogram or the R line, depending on whether you want divergence measured on the cleaner momentum component or on the combined series. “Key off pivots” determines whether pivot detection is driven by oscillator pivots or by price pivots. If you choose oscillator pivots, divergence anchors are found where the oscillator makes pivot highs or lows and those are compared against price at the same points. If you choose price pivots, the pivots are taken from price first and the oscillator value at those pivot bars is used for the comparison, which can feel more intuitive when you want divergence to respect obvious swing structure on the chart. Pivot Left and Pivot Right control how strict the swing definition is, larger values create fewer but more meaningful pivots and smaller values create more frequent signals. “Mark on Price Chart” adds tiny markers on the candles at the pivot location so you can see where the divergence event was confirmed, while the oscillator panel uses lines and labels to make the divergence relationship obvious.
For trading, the cleanest way to use this tool is to separate “bias” from “timing.” The RBF Price Trail is your bias filter because it is structure-like and tends to hold and ratchet rather than constantly drifting. When price is closing above the trail and the trail is colored bullish, you treat the market as long-biased and you focus on long setups, pullbacks, and continuation entries. When price is closing below the trail and the trail is bearish, you treat the market as short-biased and you focus on short setups, rallies, and continuation shorts. The PPO histogram is then your timing and pressure confirmation. In an up-bias, the highest quality continuation conditions are when the histogram is above zero and stays above zero through pullbacks, because that means the shorter-term pressure is still supporting the longer-term drift. When the histogram dips below zero during an up-bias, it is a warning that the daily component is now opposing, which often corresponds to a deeper pullback, a rotation, or a period of consolidation, so you either wait for the histogram to recover above zero or you tighten expectations and manage risk more aggressively. In a down-bias, the mirror logic applies: the best continuation conditions are when the histogram is below zero, and pushes above zero tend to represent countertrend rotations or pauses inside the bearish condition.
Divergence is best used as an early warning and a location filter, not as a standalone entry button. Regular bullish divergence, where price makes a lower low but the oscillator makes a higher low, can signal bearish pressure is weakening and is most useful when it appears while price is below the RBF trail but failing to continue downward, because it often precedes a reclaim of the trail or at least a meaningful rotation. Regular bearish divergence, where price makes a higher high but the oscillator makes a lower high, can signal bullish pressure is weakening and is most useful when it appears while price is above the trail but extension is failing, because it often precedes a drop back to the trail or a full flip. Hidden divergence is a continuation concept. Hidden bullish divergence, where price makes a higher low while the oscillator makes a lower low, often shows up during pullbacks in an uptrend and can help you confirm continuation as long as the RBF bias remains bullish. Hidden bearish divergence, where price makes a lower high while the oscillator makes a higher high, often shows up during rallies in a downtrend and can help you confirm continuation as long as the RBF bias remains bearish. In practice, you’ll get the best results when you only act on divergence that aligns with the RBF bias for hidden divergence continuation, and you treat regular divergence as a caution or reversal setup only when it occurs near a meaningful swing and is followed by a bias change or a strong momentum shift on the PPO.
The most practical workflow is to keep the RBF trail visible on the price chart as your regime guide, keep the PPO histogram as your momentum confirmation, and decide in advance whether you want candle coloring to represent the PPO state or the RBF state so your eyes are not reading two different meanings at once. if you want the cleanest “trend-following” behavior, color candles by the RBF trail and use the PPO histogram as the timing trigger. If you want the cleanest “momentum-first” behavior, color candles by PPO and treat the RBF trail as the higher-level filter for whether you should press a move or fade it.
BTC vs GOLD Macro RotationBTC vs GOLD Macro Rotation Indicator
BTC vs GOLD Macro Rotation Model
This indicator is a macroeconomic rotation model that compares the relative attractiveness of Bitcoin (BTC) versus Gold (GOLD) based on multiple fundamental macro factors.
How does it work?
The model analyzes weekly data from various macroeconomic indicators and generates a score for each asset. The taller bar indicates the preferred asset to rotate capital into.
- Green bars (above zero): BTC strength
- Yellow bars (below zero):GOLD strength
- Info table:Shows exact percentages and rotation recommendation
Macroeconomic Factors Analyzed:
1. DXY (US Dollar Index)
- Strong dollar → Favors GOLD
- Weak dollar → Favors BTC
2. Oil (WTI Crude)
- Oil rising → Favors GOLD
- Oil falling → Favors BTC
3. Copper
- Copper rising → Favors BTC (risk-on)
- Copper falling → Favors GOLD (risk-off)
4. Real Rates (Fed Funds - YoY Inflation)
- Real rates falling → Favors GOLD
- Real rates rising → Favors BTC
5. Fertilizer/Natural Gas Regime (Urea, Ammonia, Natural Gas)**
- Specific combinations of movements in these commodities generate inflationary/deflationary regime signals
Fertilizer Rules:**
| Urea | Ammonia | Gas | Signal |
|------|---------|-----|--------|
| ↑ | ↑ | ↓ | GOLD +2 |
| ↑ | ↑ | ↑ | GOLD +3, BTC -1 |
| ↓ | ↓ | ↓ | BTC +3, GOLD -1 |
| ↑ | ↓ | ↓ | BTC +3 |
| ↓ | ↑ | ↑ | GOLD +3, BTC -1 |
Technical Features:
- Operates on weekly timeframe regardless of chart
- Normalized changes for signal stability
- Configurable EMA smoothing
- Safe handling of invalid symbols (won't break if a ticker doesn't exist)
- All tickers are user-editable
Configurable Inputs:
- Symbols for all assets (BTC, GOLD, DXY, Oil, Copper, CPI, Fed Funds, Gas, Urea, Ammonia)
- Individual weights for each macro component
- Normalization length
- EMA smoothing
Interpretation:**
- **BTC dominant (taller green):** Macro conditions favor risk/digital assets
- **GOLD dominant (taller yellow):** Macro conditions favor safe-haven/tangible assets
This indicator is for educational and informational purposes only. It does not constitute financial advice. Always do your own research before making investment decisions.
Recommended Timeframe: Weekly (W) or Daily (D)
Fed Balance Sheet (Candles)Fed Balance Sheet (Candles) - TradingView Description
📊 OVERVIEW
Fed Balance Sheet (Candles) transforms the Federal Reserve's total assets into an intuitive candlestick visualization, allowing you to track monetary policy changes with the same visual language you use for price action.
This indicator pulls real-time data directly from FRED (Federal Reserve Economic Data) and displays the Total Assets of All Federal Reserve Banks as dynamic candles on your chart, making it effortless to correlate central bank liquidity with market movements.
🎯 WHY THIS MATTERS
The Federal Reserve's balance sheet is one of the most powerful leading indicators in global markets. When the Fed expands its balance sheet (Quantitative Easing), it injects liquidity into the financial system, historically correlating with:
Rising asset prices (stocks, crypto, commodities)
Lower volatility
Risk-on sentiment
Currency devaluation
When the Fed contracts its balance sheet (Quantitative Tightening), liquidity drains from markets, often leading to:
Asset price pressure
Increased volatility
Risk-off sentiment
Dollar strength
By visualizing this as candles, you can instantly see:
The pace of change (candle size)
The direction (green = expansion, red = contraction)
Acceleration or deceleration (consecutive candles in same direction)
Pivots in monetary policy (color changes from green to red or vice versa)
🔧 HOW IT WORKS
Data Source
Source: Federal Reserve Economic Data (FRED)
Metric: Total Assets of All Federal Reserve Banks
Unit: Displayed in Trillions of USD for easy reading
Frequency: Weekly updates (every Wednesday)
Candlestick Construction
Since balance sheet data is reported as a single number each week (not traditional open-high-low-close), this indicator creates candles by comparing each period to the previous one:
Open = Last week's balance sheet value
Close = This week's balance sheet value
High = The higher of the two values
Low = The lower of the two values
This captures directional movement and magnitude of change, making it intuitive for traders accustomed to candlestick analysis.
Color Scheme
🟢 GREEN CANDLES (Expanding Balance Sheet)
When this week's value is higher than last week's
Interpretation: Fed is adding liquidity (Quantitative Easing)
Historically bullish for risk assets
🔴 RED CANDLES (Contracting Balance Sheet)
When this week's value is lower than last week's
Interpretation: Fed is removing liquidity (Quantitative Tightening)
Historically bearish or neutral for risk assets
Value Label
A floating label displays the current balance sheet value in trillions (e.g., "$8.75T") so you always know the exact figure at a glance.
📈 PRACTICAL APPLICATIONS
1. Market Regime Identification
Strings of green candles = Liquidity-driven bull markets
Strings of red candles = Tightening-induced bear markets or corrections
Color transitions = Potential market inflection points
2. Correlation Analysis
Overlay on stock indices (SPY, QQQ, IWM)
Overlay on crypto (BTC, ETH)
Overlay on commodities (Gold, Silver)
Observe how asset prices react to Fed liquidity changes in real-time
3. Macro Timing
Large green candles = Aggressive easing (crisis response)
Large red candles = Aggressive tightening (inflation fighting)
Small candles = Neutral policy (Fed on hold)
4. Risk Management
Shift portfolio allocation based on liquidity environment
Reduce leverage during red candle trends
Increase exposure during green candle trends
Use as confirmation for other technical signals
5. Multi-Timeframe Context
Daily charts: See how daily price action relates to weekly Fed data
Weekly charts: Perfect alignment with data release frequency
Monthly charts: Visualize long-term monetary cycles spanning years
⚙️ SETTINGS
Zero configuration needed. Simply add the indicator to any chart and it works immediately.
The indicator automatically:
Overlays on your main chart
Uses the left price scale (won't interfere with asset prices)
Updates with the latest Fed data
Displays values in trillions for clean readability
🎨 VISUAL DESIGN PHILOSOPHY
The indicator uses semi-transparent candle bodies with vibrant borders to maintain visibility without obscuring your price action. The color scheme follows universal chart conventions where green represents growth/expansion and red represents decline/contraction.
It's designed to blend seamlessly into any chart theme while providing immediate visual clarity about the Fed's monetary stance.
📚 WHAT YOU NEED TO KNOW
Data Availability
Historical data available from December 2002 (over 20 years of Fed policy)
Updates every Wednesday (Federal Reserve's reporting schedule)
Typically published with a 1-week lag
How the Data Appears
On weekdays: Shows the most recent Wednesday's data
On weekends: Shows Friday's data (which is the prior Wednesday's figure)
Updates automatically when new data is released
Scale Considerations
The Fed's balance sheet is measured in trillions, while most assets are priced much lower. The indicator uses the left price scale by default to avoid conflicts with your main asset's price scale. You can easily move it to a separate pane if you prefer.
🧠 INTERPRETATION GUIDE
Historical QE Phases (Green Candles)
2008-2014: Financial Crisis Response
The Fed's balance sheet expanded from under $1T to ~$4.5T to stabilize markets after the mortgage crisis.
2020: COVID-19 Response
Rapid expansion to ~$7T as the Fed stepped in during pandemic lockdowns.
2020-2022: Extended Support
Balance sheet reached historic peak of ~$9T.
Historical QT Phases (Red Candles)
2017-2019: First Modern QT Attempt
The Fed tried to normalize its balance sheet, reducing it from ~$4.5T to ~$3.8T before pivoting.
2022-Present: Inflation-Fighting QT
The Fed began shrinking its balance sheet to combat inflation, letting bonds mature without replacement.
Key Insights
Size matters, but rate of change matters MORE.
A $9T balance sheet growing slowly has different implications than a $5T balance sheet growing rapidly.
Watch for acceleration.
Increasingly large candles (up or down) signal a policy shift that markets will notice.
Plateaus mean "wait and see."
Tiny candles indicate the Fed is holding steady and watching economic data.
Reversals are major events.
When candles switch from green to red (or vice versa), the Fed has changed course—these are critical market turning points.
🎓 EDUCATIONAL VALUE
This indicator helps you understand:
The mechanics of monetary policy through visual learning
The lag between Fed actions and market reactions by observing temporal correlation
The scale of modern central banking (trillions put into perspective)
The relationship between liquidity and asset prices (cause and effect in action)
Many traders talk about "don't fight the Fed" but never actually track what the Fed is doing. Now you can see it as clearly as you see price action.
🔗 RELATED CONCEPTS
For comprehensive macro analysis, consider also tracking:
Fed Funds Rate (short-term interest rates)
M2 Money Supply (broader measure of money in circulation)
Treasury Yield Curves (bond market expectations)
Dollar Index (DXY) (currency strength)
VIX (market fear/volatility)
The Fed's balance sheet is just one piece of the puzzle, but it's arguably the most important one for understanding liquidity conditions.
⚠️ DISCLAIMER
This indicator displays publicly available economic data from the Federal Reserve. It is for informational and educational purposes only and does not constitute financial advice.
Important considerations:
Past monetary policy does not guarantee future market outcomes
Correlation does not equal causation
Asset prices are influenced by many factors beyond Fed liquidity
Always use proper risk management
Consult with qualified financial professionals before making investment decisions
Trading involves substantial risk of loss and is not suitable for everyone.
📜 VERSION HISTORY
Version 1.0 - Initial Release
Fed balance sheet visualized as candlesticks
Real-time FRED data integration
Automatic display in trillions
Dynamic color coding (green/red)
Current value label with exact figure
💡 WHY CANDLES?
You might wonder: "Why show the Fed's balance sheet as candles instead of a line?"
Because candles tell stories that lines can't.
A line shows you where we are
Candles show you how we got here, how fast we're moving, and what momentum looks like
Candles make the Fed's actions feel immediate and tangible
Candles connect macro data to the chart language you already speak
When you see three big green candles in a row on the Fed balance sheet while your crypto or stock portfolio is rallying, you feel the connection. When you see the candles turn red and shrink, you understand the headwinds forming.
It transforms dry economic data into actionable market intelligence.
📞 SUPPORT & FEEDBACK
If you find this indicator valuable:
⭐ Like and favorite to help others discover it
📝 Comment with your use cases and insights
🔔 Follow for updates and new macro indicators
Your feedback drives improvements and helps build better tools for the trading community.
🚀 THE BOTTOM LINE
The Fed's balance sheet is the tide that lifts or lowers all boats.
Whether you're trading stocks, crypto, forex, or commodities—whether you're a day trader or long-term investor—understanding the Fed's liquidity operations gives you an edge.
This indicator makes that understanding visual, immediate, and actionable.
Stop guessing about macro conditions. Start seeing them.
"Don't fight the Fed" - Wall Street Wisdom
Now you can see exactly what they're doing—in the same language you use to read price action.
May your trades ride the tide of liquidity. 🌊📈
Multi-Timeframe Volume Profile - Auto HVN WallsMulti-Timeframe Volume Profile - Auto HVN Walls
Overview This indicator provides a highly flexible Volume Profile solution that operates across multiple timeframes (Session, Weekly, Monthly, Yearly). Unlike standard profiles, this tool features a unique "Auto HVN Wall" detection system. It automatically identifies meaningful High Volume Nodes (HVNs) within the profile structure and extends them forward as potential support and resistance zones, creating a dynamic map of market structure as it develops.
Key Features
Multi-Timeframe Support: Switch seamlessly between Session, Weekly, Monthly, and Yearly profiles.
Auto HVN Walls (Structure Detection): The script analyzes the profile shape in real-time. When it detects significant clusters of volume (HVNs), it automatically draws extended lines ("walls"). These walls often act as magnets or support/resistance levels where price has previously found acceptance.
Session Filtering: When in "Session" mode, you can define specific time windows (e.g., 0930-1615) to isolate Regular Trading Hours (RTH) volume, ignoring overnight data.
Auto-Scaling Width (Monthly Mode): For Monthly profiles, the histogram width dynamically changes throughout the month. It starts wide at the beginning of the month to be visible and gradually narrows as the month progresses, keeping your chart clean.
High Precision: Uses lower timeframe data (user-selectable) to build the profile, ensuring accuracy even on higher timeframe charts.
Alerts: Built-in alert conditions for price crossing the developing POC, VAH, or VAL.
How It Works
Data Accumulation: The script fetches lower timeframe volume and price data (e.g., 5-minute data on a 1-hour chart) to construct a precise volume histogram.
Wall Detection: It runs a smoothing algorithm over the volume profile. If a price level accumulates volume significantly higher than the average (controlled by the Volume Threshold Multiplier), it marks that level as a "Wall" and extends it.
Value Area: Standard Value Area High (VAH), Value Area Low (VAL), and Point of Control (POC) are calculated and displayed for the selected period.
Settings Guide
Profile Period: Choose between Session, Weekly, Monthly, or Yearly.
Session Time: (Only active in "Session" mode) Define the start and end times for the profile (e.g., 0930-1615).
Calculation Precision: Determines the lower timeframe used to build the profile. Lower is more precise but may load slower.
The Walls:
Smoothing Factor: How much to smooth the volume data before finding walls. Higher = fewer, more significant walls.
Volume Threshold: How much volume is needed to trigger a wall.
Extend Walls: If checked, walls extend infinitely to the right.
Auto-Scale Width: (Monthly Only) dynamically adjusts the profile width based on the day of the month.
Use Case This tool is ideal for auction market theorists and volume profile traders who want to visualize where value is building in real-time and identify "sticky" price levels (Walls) where the market is likely to rotate or consolidate.
Disclaimer This script and the information presented here are for educational and informational purposes only. They do not constitute financial advice, investment recommendations, or trading signals. Trading in financial markets involves a significant risk of loss and is not suitable for all investors. Past performance of any trading system or methodology is not necessarily indicative of future results. Use this tool at your own discretion and risk.
Previous HLC Single ChoiceThis indicator allows traders to visualize the High, Low, and Close (HLC) levels of a previous timeframe directly on their current chart. By plotting these key levels from a higher timeframe, traders can identify significant support and resistance zones, potential breakout levels, and the overall market context without needing to switch back and forth between different chart intervals.
How it Works
The script utilizes the request.security() function to fetch the High, Low, and Close data from the previous completed bar of a user-selected timeframe.
Unlike static multi-timeframe indicators that might clutter the chart with too many lines, this script is designed for simplicity and flexibility. It uses the input.timeframe functionality, allowing you to select any standard or custom timeframe available on TradingView (e.g., 4-hour, Daily, Weekly, 3-Month, 12-Month) via a simple dropdown menu.
Once a timeframe is selected, the indicator plots three distinct lines:
Green Line: The High of the previous timeframe.
Red Line: The Low of the previous timeframe.
Orange Line: The Close of the previous timeframe.
Usage Examples
These levels often act as dynamic support and resistance.
Breakouts: A move above the previous timeframe's High can signal bullish strength.
Breakdowns: A drop below the previous timeframe's Low can signal bearish weakness.
Ranges: The space between the High and Low often defines the trading range for the current session.
Screenshots
Ethereum (1D Chart / 6M Levels):
Here we see the 6-Month High, Low, and Close plotted on a Daily chart. Note how the previous 6-month levels frame the long-term trend.
Silver (2h Chart / 1W Levels):
This example shows Silver on a 2-hour chart with Weekly levels. This is useful for intraday traders looking for weekly pivots.
EURUSD (30m Chart / 480m Levels):
A granular look at the Euro on a 30-minute chart using an 8-hour (480m) timeframe overlay. This helps identify mid-session reversals.
Apple (1D Chart / 3M Levels):
Apple stock on a Daily chart with Quarterly (3-Month) levels, highlighting major structural levels for swing trading.
Settings
Choose Timeframe: Select the specific timeframe you wish to overlay (Default is 3 Months).
Disclaimer
This script is for educational and informational purposes only. It DOES NOT constitute financial advice. Past performance is not indicative of future results. Always do your own research and risk management before trading.
QTاندیکاتور "QT" در پلتفرم TradingView یک ابزار پیشرفته برای تجزیه و تحلیل بازار است که از چندین چرخه زمانی مختلف بهره میبرد. این اندیکاتور به شما کمک میکند تا نقاط بحرانی در بازههای زمانی مختلف (سالیانه، ماهانه، هفتگی، روزانه، 90 دقیقهای و میکرو) را شناسایی کنید. ویژگی برجسته این اندیکاتور، استفاده از SSMT (Same Cycle Multiple Timeframes) و PSP (Price Signal Patterns) برای ارائه سیگنالهای دقیقتر است. این دو بخش باعث میشوند که اندیکاتور "QT" به ابزاری قدرتمند برای تریدرها تبدیل شود.
ویژگیهای اصلی:
SSMT (Same Cycle Multiple Timeframes):
SSMT یک روش تجزیه و تحلیل پیشرفته است که در آن یک چرخه زمانی خاص بهطور همزمان در چندین تایم فریم مختلف رصد میشود. این اندیکاتور با استفاده از SSMT، به شما این امکان را میدهد که تغییرات قیمت در تایم فریمهای مختلف را مقایسه کنید و سیگنالهایی که در چندین تایم فریم همزمان فعال هستند، شناسایی کنید.
این سیگنالها میتوانند به شما کمک کنند که نقاط ورود و خروج بهتری داشته باشید، چرا که تایید شدن سیگنال در چند تایم فریم به معنای اعتبار بالای آن است.
به عنوان مثال، زمانی که یک شکست قیمتی در تایم فریم روزانه رخ میدهد و همزمان در تایم فریمهای هفتگی و ماهانه هم تأیید میشود، احتمال اینکه این حرکت ادامهدار باشد، بسیار بالا خواهد بود.
SSMT قابلیت تنظیم دارد و میتوانید آن را بر اساس نیاز خود بهطور سفارشی تنظیم کنید، از جمله تعیین نحوه نمایش علامتها، رنگها و خطوط سیگنال.
PSP (Price Signal Patterns):
PSP یکی از بخشهای کلیدی اندیکاتور QT است که از الگوهای خاص قیمتی برای شناسایی تغییرات مهم در بازار استفاده میکند. این الگوها میتوانند شامل شکستها (Breakouts)، برگشتها (Reversals) و تغییرات روند (Trend Changes) باشند.
اندیکاتور PSP از دو نماد مختلف برای مقایسه استفاده میکند (مثلاً "SPY" و "QQQ") و نقاطی که این نمادها با یکدیگر دچار انحراف میشوند را شناسایی میکند. به عنوان مثال، اگر یک نماد صعودی باشد اما دیگری نزولی باشد، این میتواند بهعنوان یک هشدار برای تغییر روند بازار عمل کند.
در کنار این الگوها، این اندیکاتور از نشانگرهای گرافیکی (مانند مثلثها، فلشها و علامتهای دایرهای) برای نمایش این تغییرات استفاده میکند.
PSP همچنین این امکان را به شما میدهد که سیگنالهای قیمتی را در تایم فریمهای مختلف مشاهده کرده و تصمیمات دقیقتری بگیرید.
چرخههای زمانی و جعبهها:
اندیکاتور QT از جعبههای زمانی برای نمایش تغییرات در چارچوبهای زمانی مختلف (سالیانه، ماهانه، هفتگی و غیره) استفاده میکند.
این جعبهها میتوانند بهطور خودکار و با تنظیمات سفارشی شما رسم شوند، بهطوری که شما میتوانید روندهای مختلف بازار را در تایم فریمهای متفاوت مشاهده کنید.
بهطور کلی، این ویژگی به شما کمک میکند که نقاط حمایت و مقاومت مهم در زمانهای مختلف بازار را شناسایی کنید.
گرافیک و سفارشیسازی:
این اندیکاتور به شما این امکان را میدهد که رنگها، اندازهها، و استایلهای گرافیکی را به دلخواه خود تغییر دهید. این ویژگی به تریدرها این امکان را میدهد که ابزار را با توجه به نیاز خود شخصیسازی کنند.
همچنین، از آنجا که این اندیکاتور از چندین چرخه زمانی استفاده میکند، شما میتوانید هرکدام از این چرخهها را با استایلهای مختلف نمایش دهید، مثل استفاده از خطچین، نقطهچین یا خطهای عادی.
خلاصه:
اندیکاتور "QT" با استفاده از تکنیکهای پیشرفته مانند SSMT و PSP، تجزیه و تحلیل بازار را در چندین تایم فریم مختلف برای شما امکانپذیر میسازد. این اندیکاتور با تحلیل دقیق چرخههای زمانی مختلف و شناسایی الگوهای قیمتی، سیگنالهایی را برای ورود و خروج به بازار به شما ارائه میدهد که میتواند بهطور قابلتوجهی به استراتژی معاملاتی شما کمک کند.
English:
Detailed Description of QT Indicator with Focus on SSMT and PSP:
The "QT" indicator on TradingView is an advanced tool designed for market analysis using multiple time cycles. It provides traders with a comprehensive view of market trends across different time frames (Yearly, Monthly, Weekly, Daily, 90-minute, and Micro). The standout feature of this indicator is its utilization of SSMT (Same Cycle Multiple Timeframes) and PSP (Price Signal Patterns), which enhances its ability to deliver more accurate signals. These two components make the "QT" indicator a powerful tool for traders.
Main Features:
SSMT (Same Cycle Multiple Timeframes):
SSMT is an advanced analysis technique that monitors a specific cycle across multiple time frames simultaneously. By using SSMT, this indicator allows traders to compare price changes across different time frames and identify signals that are active across multiple time frames.
These signals help traders identify high-probability entry and exit points because when a signal is confirmed across several time frames, it indicates a strong likelihood of a sustained price move.
For example, if a price breakout occurs on the daily time frame and is simultaneously confirmed on the weekly and monthly time frames, it is more likely to continue.
SSMT is highly customizable, allowing traders to adjust how markers, colors, and signal lines are displayed based on their preferences.
PSP (Price Signal Patterns):
PSP is one of the key components of the QT indicator that uses specific price patterns to identify significant market changes. These patterns can include breakouts, reversals, and trend changes.
The indicator utilizes two symbols (e.g., "SPY" and "QQQ") to compare and identify when these symbols diverge, signaling potential market shifts. For instance, if one symbol is bullish while another is bearish, this could signal a change in market direction.
In addition to these patterns, the indicator uses graphical markers (such as triangles, arrows, and circles) to visually represent these market changes and signals.
PSP allows traders to view price signals across different time frames, helping them make more informed decisions.
Time Cycles and Boxes:
The QT indicator uses time boxes to visually display price changes across different time frames (Yearly, Monthly, Weekly, etc.).
These boxes are automatically drawn and can be customized based on the user's settings, allowing traders to observe market trends across various periods.
Overall, this feature helps traders identify critical support and resistance levels at different points in time.
Graphics and Customization:
This indicator allows traders to customize colors, sizes, and graphical styles to fit their needs.
Additionally, since the indicator uses multiple time cycles, traders can display each cycle with different styles, such as solid, dotted, or dashed lines.
Summary:
The "QT" indicator, using advanced techniques like SSMT and PSP, allows traders to analyze the market across multiple time frames. By detecting significant price patterns and utilizing time cycles, the QT indicator provides high-probability signals for market entry and exit. This can greatly assist in enhancing your trading strategy.






















