RSI Ignoring Gaps Between DaysThe RSI Ignoring Gaps Between Days indicator is an advanced modification of the traditional Relative Strength Index (RSI) designed to exclude price gaps that occur between the last bar of one trading day and the first bar of the next. This ensures that the RSI calculations remain focused on the actual price action during the trading session, avoiding distortions caused by overnight price gaps.
Key Features:
Gap Ignoring Mechanism: The indicator detects when a new day begins and skips the price change between the last bar of the previous day and the first bar of the current day. This ensures that only the intra-day price changes are included in the RSI calculation.
Intra-day Price Movement: The RSI calculations are based on real price changes within each trading day, providing a clearer reflection of momentum without interference from overnight events.
Dynamic RSI Calculation: The traditional RSI formula is preserved, but gains and losses are recalculated based on price changes from bar to bar within the same day.
Overbought/Oversold Levels: The indicator retains standard RSI overbought (70) and oversold (30) levels, allowing traders to easily identify potential reversal zones.
Alerts for Crossovers: Built-in alert conditions trigger when the RSI crosses key levels (30 or 70), signaling potential buying or selling opportunities.
This indicator is particularly useful for traders looking to focus on intra-day price action and avoid the influence of gaps caused by overnight market activity. It is suitable for intraday trading strategies where consistency in price movement measurement is crucial.
Indicadores y estrategias
Stochastic RSI OHLC StrategyThe script titled "Stochastic RSI High Low Close Bars" is a versatile trading strategy implemented in Pine Script, designed for TradingView. Here's an overview of its features:
Description
This strategy leverages the Stochastic RSI to determine entry and exit signals in the market, focusing on high, low, and close values of the indicator. It incorporates various trading styles, stop-loss mechanisms, and multi-timeframe analysis to adapt to different market conditions.
Key Features
Stochastic RSI Analysis:
Uses the Stochastic RSI to identify potential entry points for long and short positions.
Tracks high, low, and close values for more granular analysis.
Multiple Trading Styles:
Supports diverse trading styles like Volume Color Swing, RSI Divergence, RSI Pullback, and more.
Allows switching between these styles to suit market dynamics.
Session-Based Trading:
Offers session control, limiting trades to specific hours (e.g., NY sessions).
Can close all positions at the end of the trading day.
Stop-Loss and Take-Profit Mechanisms:
Includes both static and dynamic stop-losses, with options for time-based stops, trailing stops, and momentum-based exits.
Customizable take-profit levels ensure efficient trade management.
Volume Analysis:
Integrates volume indicators to add a bias for trade entries and exits, enhancing signal reliability.
Multi-Timeframe Integration:
Employs multi-timeframe RSI analysis, allowing the strategy to capture broader trends and optimize entries.
This script is designed to provide flexibility and adaptability, making it useful for different trading strategies and market conditions. It is suitable for traders looking to refine their entries and exits with a focus on the Stochastic RSI.
AndreundCristianIndicator Overview:
The "Trade Signals with Volume" indicator is a custom script that generates buy and sell signals based on the crossover of two moving averages (a fast one and a slow one) and adds a volume filter to validate these signals. It plots these signals directly on the chart, using arrows or labels to indicate where buy and sell signals occur.
Key Features:
Moving Averages (MA):
The indicator uses two Simple Moving Averages (SMA): a fast SMA and a slow SMA.
A buy signal is triggered when the fast MA crosses above the slow MA, signaling potential bullish momentum.
A sell signal is triggered when the fast MA crosses below the slow MA, indicating potential bearish momentum.
Volume Filter:
To ensure that signals are more reliable, the indicator only triggers a buy or sell signal if the volume is above a certain threshold. This threshold can be adjusted by the user in the input settings.
For example, if the volume exceeds 100,000 (or any set value), and a crossover occurs, the signal is validated.
Visual Representation:
Buy signals are represented with green labels or arrows below the price bars.
Sell signals are represented with red labels or arrows above the price bars.
The MAs are also plotted on the chart for visual reference.
Input Parameters:
Fast Moving Average Length: The number of periods for the fast SMA (default is 9 periods).
Slow Moving Average Length: The number of periods for the slow SMA (default is 21 periods).
Volume Threshold: The minimum volume required to validate a buy or sell signal (default is 100,000).
NYSE, Euronext, and Shanghai Stock Exchange Hours IndicatorNYSE, Euronext, and Shanghai Stock Exchange Hours Indicator
This script is designed to enhance your trading experience by visually marking the opening and closing hours of major global stock exchanges: the New York Stock Exchange (NYSE), Euronext, and Shanghai Stock Exchange. By adding vertical lines and background fills during trading sessions, it helps traders quickly identify these critical periods, potentially informing better trading decisions.
Features of This Indicator:
NYSE, Euronext, and Shanghai Stock Exchange Hours: Displays vertical lines at market open and close times for these three exchanges. You can easily switch between showing or hiding the different exchanges to customize the indicator for your needs.
Background Fill: Highlights the trading hours of these exchanges using faint background colors, making it easy to spot when markets are in session. This feature is crucial for timing trades around overlapping trading hours and volume peaks.
Customizable Visuals: Adjust the color, line style (solid, dotted, dashed), and line width to match your preferences, making the indicator both functional and visually aligned with your chart's aesthetics.
How to Use the Indicator:
Add the Indicator to Your Chart: Add the script to your chart from the TradingView script library. Once added, the indicator will automatically plot vertical lines at the opening and closing times of the NYSE, Euronext, and Shanghai Stock Exchange.
Customize Display Settings: Choose which exchanges to display by enabling or disabling the NYSE, Euronext, or Shanghai sessions in the indicator settings. This allows you to focus only on the exchanges that are relevant to your trading strategy.
Adjust Visual Properties: Customize the appearance of the vertical lines and background fill through the settings. Modify the color of each exchange, adjust the line style (solid, dotted, dashed), and control the line thickness to suit your chart preferences. The background fill can also be customized to clearly highlight active trading sessions.
Identify Key Market Hours: Use the vertical lines and background fills to identify the market open and close times. This is particularly useful for understanding how price action changes during specific trading hours or for finding high liquidity periods when multiple markets are open simultaneously.
Adapt Trading Strategies: By knowing when major stock exchanges are open, you can adapt your trading strategy to take advantage of potential price movements, increased volatility, or volume. This can help you avoid low-liquidity times and capitalize on more active trading periods.
This indicator is especially valuable for traders focusing on cross-market dynamics or those interested in understanding how different sessions influence market liquidity and price action. With this tool, you can gain insight into market conditions and adapt your trading strategies accordingly. The clean visual separation of session times helps you maintain context, whether you're trading Forex, stocks, or cryptocurrencies.
Disclaimer: This script is intended for informational and educational purposes only. It does not constitute financial advice or a recommendation to buy or sell any financial instrument. Always conduct your own research and consult with a licensed financial advisor before making any trading decisions. Trading involves risk, and past performance is not indicative of future results.
Portfolio SnapShot v0.3Here is a Tradingview Pinescript that I call "Portfolio Snapshot". It is based on two other separate scripts that I combined, modified and simplified - shoutout to RedKTrader (Portfolio Tracker - Table Version) and FriendOfTheTrend (Portfolio Tracker For Stocks & Crypto) for their inspiration and code. I was using both of these scripts, and decided to combine the two and increase the number of stocks to 20. I was looking for an easy way to track my entire portfolio (scattered across 5 accounts) PnL on a total and stock basis. PnL - that's it, very simple by design. The features are:
1) Track PnL across multiple accounts, from inception and current day.
2) PnL is reported in two tables, at the portfolio level and individual stock level
3) Both tables can be turned on/off and placed anywhere on the chart.
4) Input up to 20 assets (stocks, crypto, ETFs)
The user has to manually calculate total shares and average basis for stocks in multiple accounts, and then inputs this in the user input dialog. I update mine as each trade is made, or you can just update once a week or so.
I've pre-loaded it with the major indices and sector ETFs, plus URA, GLD, SLV. 100 shares of each, and prices are based on the close Jan 2 2024. So if you don't want to track your portfolio, you can use it to track other things you find interesting, such as annual performance of each sector.
OBV based on Heikin-AshiDescription
This indicator calculates the On-Balance Volume (OBV) based on Heikin-Ashi candles rather than regular candlesticks.
OBV based on Heikin-Ashi: The OBV is calculated based on Heikin-Ashi candle trends. Volume is added when the Heikin-Ashi close is above the open (bullish) and subtracted when the close is below the open (bearish).
Volume Analysis: This approach helps traders identify significant volume shifts in a smoother trend environment, reducing market noise that often accompanies traditional candlestick charts.
説明
このインジケーターは、通常のローソク足ではなく、平均足(Heikin-Ashi)を基にオンバランス・ボリューム(OBV)を計算します。
平均足に基づくOBV: OBVは、平均足のトレンドに基づいて計算されます。平均足の終値が始値を上回った場合(陽線)は出来高が加算され、終値が始値を下回った場合(陰線)は出来高が減算されます。
出来高分析: この手法により、通常のローソク足チャートで発生するノイズを軽減し、滑らかなトレンド環境で重要な出来高の変化を把握できます。
Prometheus Fractal-Based TrendThe Fractal-Based Trend indicator is a tool that uses fractals to try and detect which direction an underlying will continue to go.
Calculation:
A bullish fractal occurs when the current bar's high is lower than the previous bar high, and the previous bar's high is higher than both the high from two bars ago and the high from three bars ago.
A bearish fractal happens when the current bar's low is higher than the previous bar's low, and the previous bar's low is lower than both the low from two bars ago and the low from three bars ago.
When a bullish or bearish fractal forms, the corresponding value stored is the previous bar high for a bearish fractal or the previous bar's low for a bullish fractal.
The trade scenarios are when these fractals occur, a green or red label being plotted on the chart for whatever direction it predicts.
Trade examples:
We see on this daily chart of AMEX:SPY that the fractals represent the potential for a directional trade that can last a few days. The more volatile a chart is the more of these fractals we can see.
We see on this 5 minute chart for NASDAQ:TSLA there is way more activity, there are more sporadic candles on a lower time frame, so we can see more anomalies in the price action.
We see this to be true for BITSTAMP:BTCUSD even on a daily time frame, since it is very volatile. There are a lot of these labels plotted.
This is the perspective we aim to provide. We encourage traders to not follow indicators blindly. No indicator is 100% accurate. This one can give you a different perspective of price strength with volatility. We encourage any comments about desired updates or criticism!
Memecoin TrackerMemecoin Z-Score Tracker with Buy/Sell Table - Technical Explanation
How it Works:
This indicator calculates the Z-scores of various memecoins based on their price movements, using historical funding rates across multiple exchanges. A Z-score measures the deviation of the current price from its moving average, expressed in standard deviations. This provides insight into whether a coin is overbought (positive Z-score) or oversold (negative Z-score) relative to its recent history.
Key Components:
- Z-Score Calculation
- The lookback period is dynamically adjusted based on the chart’s timeframe to ensure consistency across different time intervals:
- For lower timeframes (e.g., minutes), the base lookback period is scaled to match approximately 240 minutes.
- For daily and higher timeframes, the base lookback period is fixed (e.g., 14 bars).
Memecoin Selection:
The indicator tracks several popular memecoins, including DOGE, SHIB, PEPE, FLOKI, and others.
Funding rates are fetched from exchanges like Binance, Bybit, and MEXC using the request.security() function, ensuring accurate real-time price data.
Thresholds for Buy/Sell Signals:
Users can set custom Z-score thresholds for buy (oversold) and sell (overbought) signals:
Default upper threshold: 2.5 (indicates overbought condition).
Default lower threshold: -2.5 (indicates oversold condition).
When a memecoin’s Z-score crosses above or below these thresholds, it signals potential buy or sell conditions.
Buy/Sell Table:
A table with two columns (BUY and SELL) is dynamically populated with memecoins that are currently oversold (buy signal) or overbought (sell signal).
Each column can hold up to 20 entries, providing a clear overview of current market opportunities.
Visual Feedback:
The Z-scores of each memecoin are plotted as a line on the chart, with color-coded feedback:
Red for overbought (Z-score > upper threshold),
Green for oversold (Z-score < lower threshold),
Other colors indicate neutral conditions.
Horizontal lines representing the upper and lower thresholds are plotted for reference.
How to Use It:
Adjust Thresholds:
You can modify the upper and lower Z-score thresholds in the settings to customize sensitivity. Lower thresholds will increase the likelihood of triggering buy/sell signals for smaller price deviations, while higher thresholds will focus on more extreme conditions.
View Real-Time Signals:
The table shows which memecoins are currently oversold (buy column) or overbought (sell column), updating dynamically as price data changes. Traders can monitor this table to identify trading opportunities quickly.
Use with Different Timeframes:
The Z-score lookback period adjusts automatically based on the chart's timeframe, making this indicator suitable for intraday and long-term traders.
Use shorter timeframes (e.g., 1-minute, 5-minute charts) for faster signals, while longer timeframes (e.g., daily, weekly) may yield more stable, trend-based signals.
Who It Is For:
Short-Term Traders: Those looking to capitalize on short-term price imbalances (e.g., day traders, scalpers) can use this indicator to identify quick buy/sell opportunities as memecoins oscillate around their moving averages.
Swing Traders: Swing traders can use the Z-score tracker to identify overbought or oversold conditions across multiple memecoins and ride the reversals back toward equilibrium.
Crypto Enthusiasts and Memecoin Investors: Anyone involved in the volatile memecoin market can use this tool to better time entries and exits based on market extremes.
This indicator is for traders seeking quantitative analysis of price extremes in memecoins. By tracking the Z-scores across multiple coins and dynamically updating buy/sell opportunities in a table, it provides a systematic approach to identifying trade setups.
Fetch Z-scoreThis script is enspired by the creator of the Z-score probability indicator made by www.tradingview.com
I took his calculation for the z-score and created my own strategy based on that z-score.
What is z-score? The Z-score represents how far the current price deviates from the moving average, measured in terms of standard deviations
What does this script do with the Z-score?
The script offers several customizable options, including displaying buy and sell signals based on Z-score thresholds and overlaying these signals directly on the chart or below/above the bars.
The idea is that when the Z-score exceeds a certain treshold, a count will start. The count will lead to a signal. For example: Say the Z-score dipped below -1. From there, the script will by default count whether the current Z-score is higher than the Z-score of the past 10 datapoints. If so, a buy signal will be printed on the chart. The idea is that the Z-score will creep up after a low, making sure you buy earyly in the new uptrend, making this a trend followiung system, with early trend detection.
You can choose whether you want the buy and sell signals on the seperate pane, or on the chart by toggeling a simple setting.
What are my favorite settings?
- Timeframe: weekly
- SMA Length: 75
- Z score buy treshold: -1.5
- Z score sell treshold: 3
- Lookback buy period: 20
- Lookback sell period: 20
Market Phases [OmegaTools]The Market Phases indicator utilizes the Detrended Price Oscillator (DPO) to assess various asset classes, bonds, or stock sectors across different market phases. It offers users the ability to monitor and compare trends in multiple markets through a normalized DPO approach, providing insights into relative overbought or oversold conditions. The indicator supports three distinct modes: "Asset Classes," "Bonds," and "Stock Sectors," allowing flexibility in market analysis based on user preference.
Key Features:
Detrended Price Oscillator (DPO) Calculation: The DPO is computed to remove longer-term trends and focus on shorter-term cyclical behavior. The indicator applies normalization using linear interpolation to smooth out the values for better comparison across different markets.
Three Analysis Modes:
Asset Classes: Compares the DPO for major asset classes, including stocks (S&P 500), bonds (US 10-Year), commodities (Gold), and the US Dollar Index (DXY).
Bonds: Analyzes the DPO across various bond categories such as investment-grade bonds (LQD), high-yield bonds (HYG), emerging market bonds (EMB), and corporate bonds.
Stock Sectors: Provides insight into key stock sectors, including Technology (XLK), Utilities (XLU), Financials (XLF), and Healthcare (XLV).
Real-Time Plotting:
The indicator plots the DPO values of the selected assets, bonds, or sectors on the chart. It provides a visual representation of the market phases, helping to identify potential market reversals or trends. Each plot is color-coded for clarity:
Blue: Asset/Sector 1
Red: Asset/Sector 2
Green: Asset/Sector 3
Orange: Asset/Sector 4
Table Display:
A dynamic table is displayed on the chart, showing the DPO values for the selected mode's assets or sectors. This allows quick comparison and evaluation of market trends.
Inputs:
DPO Length: Defines the lookback period for DPO calculation, adjustable between 10 and 500.
Normalization Length: Sets the length for normalizing the DPO values, with options ranging from 100 to 2000.
Mode: Choose between "Asset Classes," "Bonds," or "Stock Sectors" for tailored market analysis.
This tool is perfect for traders seeking to identify cyclical market phases, compare different asset classes, or monitor sector rotation dynamics. Use it to align your trading strategies with broader market trends and uncover potential trading opportunities across multiple markets.
Liquidations Zones [ChartPrime]The Liquidation Zones indicator is designed to detect potential liquidation zones based on common leverage levels such as 10x, 25x, 50x, and 100x. By calculating percentage distances from recent pivot points, the indicator shows where leveraged positions are most likely to get liquidated. It also tracks buy and sell volumes in these zones, helping traders assess market pressure and predict liquidation scenarios. Additionally, the indicator features a heat map mode to highlight areas where orders and stop-losses might be clustered.
⯁ KEY FEATURES AND HOW TO USE
⯌ Leverage Zones Detection :
The indicator identifies zones where positions with leverage ratios of 100x, 50x, 25x, and 10x are at risk of liquidation. These zones are based on percentage moves from recent pivots: a 1% move can liquidate 100x positions, a 4% move affects 25x positions, and so on.
⯌ Liquidated Zones and Volume Tracking :
The indicator displays liquidated zones by plotting gray areas where the price potentually liquidate positons. It calculates the volume needed to liquidate positions in these zones, showing volume from bullish candles if short positions were liquidated and volume from bearish candles for long positions. This feature helps traders assess the risk of liquidation as the price approaches these zones.
⯌ Buy/Sell Volume Calculation :
Buy and sell volumes are calculated from the most recent pivot high or low. For buy volume, only bullish candles are considered, while for sell volume, only bearish candles are summed. This data helps traders gauge the strength of potential liquidation in different zones.
Example of buy and sell volume tracking in active zones:
⯌ Liquidity Heat Map :
In heat map mode, the indicator visualizes potential liquidity areas where orders and stop-losses may be clustered. This map highlights zones that are likely to experience liquidations based on leverage ratios. Additionally, it tracks the highest and lowest price levels for the past 100 bars, while also displaying buy and sell volumes. This feature is useful for predicting market moves driven by liquidation events.
⯁ USER INPUTS
Length : Determines the number of bars used to calculate pivots for liquidation zones.
Extend : Controls how far the liquidation zones are extended on the chart.
Leverage Options : Toggle options to display zones for different leverage levels: 10x, 25x, 50x, and 100x.
Display Heat Map : Enables or disables the liquidity heat map feature.
⯁ CONCLUSION
The Liquidation Zones indicator provides a powerful tool for identifying potential liquidation zones, tracking volume pressure, and visualizing liquidity areas on the chart. With its real-time updates and multiple features, this indicator offers valuable insights for managing risk and anticipating market moves driven by leveraged positions.
DYNAMIC USD MOMENTUM INDICATOR
Hello traders,
Welcome to my script, an indicator helping you to quickly see the performance of USD in constant daily comparison to other currencies.
This script requests price data from other charts but displays overbought and oversold labels on any selected chart currency pair.
See attached images to spot high probability reversal days when USD is in extremes against multiple other currencies. The output labels represent the currency traded against USD and reaching overbought and oversold zoned on a dynamic RSI scale.
Suggested pairs with higher co relation to stronger or weaker dollar:
AUD/USD, CAD/USD, EUR/USD, GBP/USD, NZD/USD
CHF/USD and JPY/USD require more in depth analysis of individual performance of JPY AND CHF
Ehlers Loops [BigBeluga]The Ehlers Loops indicator is based on the concepts developed by John F. Ehlers, which provide a visual representation of the relationship between price and volume dynamics. This tool helps traders predict future market movements by observing how price and volume data interact within four distinct quadrants of the loop, each representing different combinations of price and volume directions. The unique structure of this indicator provides insights into the strength and direction of market trends, offering a clearer perspective on price behavior relative to volume.
🔵 KEY FEATURES & USAGE
● Four Price-Volume Quadrants:
The Ehlers Loops chart consists of four quadrants:
+Price & +Volume (top-right) – Typically indicates a bullish continuation in the market.
-Price & +Volume (bottom-right) – Generally shows a bearish continuation.
+Price & -Volume (top-left) – Typically indicates an exhaustion of demand with a potential reversal.
-Price & -Volume (bottom-left) – Indicates exhaustion of supply and near trend reversal.
By watching how symbols move through these quadrants over time, traders can assess shifts in momentum and volume flow.
● Price and Volume Scaling in Standard Deviations:
Both price and volume data are individually filtered using HighPass and SuperSmoother filters, which transform them into band-limited signals with zero mean. This scaling allows traders to view data in terms of its deviation from the average, making it easier to spot abnormal movements or trends in both price and volume.
● Loops Trajectories with Tails:
The loops draw a trail of price and volume dynamics over time, allowing traders to observe historical price-volume interactions and predict future movements based on the curvature and direction of the rotation.
● Price & Volume Histograms:
On the right side of the chart, histograms for each symbol provide a summary of the most recent price and volume values. These histograms allow traders to easily compare the strength and direction of multiple assets and evaluate market conditions at a glance.
● Flexible Symbol Display & Customization:
Traders can select up to five different symbols to be displayed within the Ehlers Loops. The settings also allow customization of symbol size, colors, and visibility of the histograms. Additionally, traders can adjust the LPPeriod and HPPeriod to change the smoothness and lag of the loops, with a shorter LPPeriod offering more responsiveness and a longer HPPeriod emphasizing longer-term trends.
🔵 USAGE
🔵 SETTINGS
Low pass Period: default is 10 to
obtain minimum lag with just a little smoothing.
High pass Period: default is 125 (half of the year if Daily timeframe) to capture the longer term moves.
🔵 CONCLUSION
The Ehlers Loops indicator offers a visually rich and highly customizable way to observe price and volume dynamics across multiple assets. By using band-limited signals and scaling data into standard deviations, traders gain a powerful tool for identifying market trends and predicting future movements. Whether you're tracking short-term fluctuations or long-term trends, Ehlers Loops can help you stay ahead of the market by offering key insights into the relationship between price and volume.
UTC Discipline TradingReminder for Disciplined Trading:
1.Trend Trading – We only open positions in the direction of the trend to take advantage of market momentum.
2.SMC Zones – We trade only within zones defined by the Smart Money Concept (SMC) indicator, identifying key market points.
3.Risk 0.5% – Each position carries a maximum risk of 0.5% of total capital, minimizing potential losses and maintaining risk control.
4.3RR – Every trade must have a risk-to-reward ratio (RR) of 3:1, meaning the potential reward should be three times greater than the risk.
5.DDD -1.5% – When the daily loss reaches -1.5%, trading for the day is closed to avoid further losses.
6.DW 2+% – When daily profit reaches 2%, trading for the day ends. However, if profit exceeds 2%, you may risk an additional amount, and in case of a loss, the day will close with at least 2% profit.
Zone Color PatternZone Color Pattern indicator depicts the color pattern of zones on chart. This will help the user to identify the zones on Chart.
Green Zone is indicated by Green color.
Red Zone is indicated by Red Color.
Gray Zone is indicated by Gray Zone.
Zone Color Pattern indicator is based on 3 moving averages. Long term, Medium term and Short Term.By default they are 200, 50 and 20.
When you are on long term trend the position of MAs is 20 MA is on top,then comes 50 MA and 200 MA is positioned below 50 MA.The position of respective MAs change during down trend.
The color patterns display the distance between different MAs .The widening and contraction of space between different Moving Averages indicate the movement and direction of price.
Basically price tend to move in and move away from Average. This action tend to create a space between price and MAs.Color patterns between price and MAs reflect the gap between the price and M|As .All these effects can be visualized on chart in relevant colors to infer the status of price, movement, cross over by the User.
Buy trades are preferred when close is in Green Zone and price is above MA20.
Sell trades are preferred when close is in Red Zone and price is below MA20
Trades may be avoided when close is in Gray Zone.
Long Up Trend and Down Trend respective color triangle shapes and arrows on chart indicate the trends and direction.
The chart understanding has to be supplemented with other regular indicators along with appropriate risk reward techniques by user.
Table indicate difference between Last Price traded and Day open price.
Other columns in table display the position of close in different Zones.
DISCLAIMER: For educational and entertainment purpose only .Nothing in this content should be interpreted as financial advice or a recommendation to buy or sell any sort of security/ies or investment/s.
HTFCandlesLibLibrary "HTFCandlesLib"
Library to get detailed higher timeframe candle information
method tostring(this, delimeter)
Returns OHLC values, BarIndex of higher and lower timeframe candles in string format
Namespace types: Candle
Parameters:
this (Candle) : Current Candle object
delimeter (string) : delimeter to join the string components of the candle
Returns: String representation of the Candle
method draw(this, bullishColor, bearishColor, printDescription)
Draws the current candle using boxes and lines for body and wicks
Namespace types: Candle
Parameters:
this (Candle) : Current Candle object
bullishColor (color) : color for bullish representation
bearishColor (color) : color for bearish representation
printDescription (bool) : if set to true prints the description
Returns: Current candle object
getCurrentCandle(ltfCandles)
Gets the current candle along with reassigned ltf components. To be used with request.security to capture higher timeframe candle data
Parameters:
ltfCandles (array) : Lower timeframe Candles array
Returns: Candle object with embedded lower timeframe key candles in them
Candle
Candle represents the data related to a candle
Fields:
o (series float) : Open price of the candle
h (series float) : High price of the candle
l (series float) : Low price of the candle
c (series float) : Close price of the candle
lo (Candle) : Lower timeframe candle that records the open price of the current candle.
lh (Candle) : Lower timeframe candle that records the high price of the current candle.
ll (Candle) : Lower timeframe candle that records the low price of the current candle.
lc (Candle) : Lower timeframe candle that records the close price of the current candle.
barindex (series int) : Bar Index of the candle
bartime (series int) : Bar time of the candle
last (Candle) : Link to last candle of the series if any
Japan Stock Market Indices Performance TableYou can display the performance of the Nikkei 225 Futures and major indices of the Japanese stock market for the day in a table format on your chart.
The 5-Minute Change Rate shows the change from the opening price of the most recent 5-minute candlestick.
The Daily Change Rate displays the change from the opening price at 09:00 GMT+9 on the current trading day.
Since the Japanese stock market opens at 09:00 GMT+9 , the values for Nikkei 225 Futures, USD/JPY, and EUR/JPY are also calculated based on their opening prices at that time. This script was created because, while brokerage apps allow you to see the comparison to the previous day's close for each index, they do not display the rate of change from the current day's opening price.
Notes:
All values are reset each trading day at 09:00 GMT+9.
If you have not purchased real-time market data from the Tokyo Stock Exchange and Osaka Exchange, data may be delayed by 20 minutes and may not display correctly.
The Tokyo Stock Exchange sector indices are distributed in real-time at 15-second intervals from the TSE, so this script aligns with that timing.
当日の日経225先物と日本株式市場の主要指数のパフォーマンスを表形式でチャート上に表示することができます。
5分変化率は直近の5分足の始値からの変化率、当日変化率は当日09:00の始値からの変化率を表示しています。
日本株式市場が開くのが GMT+9 09:00 のため、それに合わせて日経225先物、ドル円、ユーロ円も GMT+9 09:00 時点の始値を元に各値を算出しています。
各指数の前日比は証券会社のアプリで見れるものの、当日始値からの変化率が見れないため作成しました。
補足
各営業日の朝(GMT+9 09:00)に各値はリセットされます。
Tokyo Stock ExchangeとOsaka Exchangeのreal-time market dataを購入していない場合、データが20分遅れになるため正常に表示されない可能性があります。
東証業種別株価指数は東証から配信されるのが15秒間隔でのリアルタイムになるため、このスクリプトもそれに準ずる形となっています。
XAUUSD Multi-Timeframe Trend AnalyzerOverview
The "XAUUSD Multi-Timeframe Trend Analyzer" is an advanced script designed to provide a comprehensive analysis of the XAUUSD (Gold/US Dollar) trend across multiple timeframes simultaneously. By combining several key technical indicators, this tool helps traders quickly assess the market direction and trend strength for M15, M30, H1, H4, and D1 timeframes.
Multi-Timeframe Analysis: Displays the trend direction and strength across M15, M30, H1, H4, and D1 timeframes, allowing for a complete overview in a single glance.
Comprehensive Indicator Blend: Utilizes six popular technical indicators to determine the trend—Moving Averages, RSI, MACD, Bollinger Bands, DMI, and Parabolic SAR.
Trend Strength Scoring: Provides a numerical trend strength score (from -6 to 6) based on the alignment of the indicators, with positive values indicating uptrends and negative values for downtrends.
Visual Table Display: Displays results in a color-coded table (green for uptrend, red for downtrend, yellow for neutral) with a strength score for each timeframe, helping traders quickly assess market conditions.
How It Works
This script calculates the overall trend and its strength for each selected timeframe by analyzing six widely-used technical indicators:
Moving Averages (MA): The script uses a Fast and a Slow Moving Average. When the Fast MA crosses above the Slow MA, it indicates an uptrend. When the Fast MA crosses below, it signals a downtrend.
Relative Strength Index (RSI): The RSI is used to assess momentum. An RSI value above 50 suggests bullish momentum, while a value below 50 suggests bearish momentum.
Moving Average Convergence Divergence (MACD): MACD measures momentum and trend direction. When the MACD line crosses above the signal line, it signals bullish momentum; when it crosses below, it signals bearish momentum.
Bollinger Bands: These measure price volatility. When the price is above the middle Bollinger Band, the script considers the trend to be bullish, and when it's below, bearish.
Directional Movement Index (DMI): The DMI compares positive directional movement (DI+) and negative directional movement (DI-). A stronger DI+ over DI- signals an uptrend and vice versa.
Parabolic SAR: This indicator is used for determining potential trend reversals and setting stop-loss levels. If the price is above the Parabolic SAR, it indicates an uptrend, and if below, a downtrend.
Trend Strength Calculation
The script calculates a trend strength score for each timeframe:
Each indicator adds or subtracts 1 to the score based on whether it aligns with an uptrend or a downtrend.
A score of 6 indicates a Strong Uptrend, with all indicators aligned bullishly.
A score of -6 indicates a Strong Downtrend, with all indicators aligned bearishly.
Intermediate scores (e.g., 2 or -2) indicate Weak Uptrend or Weak Downtrend, suggesting that not all indicators are in agreement.
A score between 1 and -1 indicates a Neutral trend, suggesting uncertainty in the market.
How to Use
Assess Trend Direction and Strength: The table provides an easy-to-read summary of the trend and its strength on different timeframes. Look for timeframes where the strength is high (either 6 for a strong uptrend or -6 for a strong downtrend) to confirm the market’s overall direction.
Use in Conjunction with Other Strategies: This indicator is designed to provide a comprehensive view of the market. Traders should combine it with other strategies, such as price action analysis or candlestick patterns, to further confirm their trades.
Trend Reversal or Continuation: A weak trend (e.g., a strength of 2 or -2) could signal a possible reversal or a trend that has lost momentum. Strong trends (with a strength of 6 or -6) indicate higher confidence in trend continuation.
Multiple Timeframe Confirmation: Look for alignment across multiple timeframes to confirm the strength and direction of the trend before entering trades. For example, if M15, M30, and H1 are all showing a strong uptrend, it suggests a higher probability of the trend continuing.
Customization Options
- Adjustable Indicators: Users can modify the length and parameters of the Moving Averages, RSI, MACD, Bollinger Bands, DMI, and Parabolic SAR to suit their trading style.
- Flexible Timeframes: You can toggle between different timeframes (M15, M30, H1, H4, D1) to focus on the intervals most relevant to your strategy.
Ideal For
- Traders looking for a detailed, multi-timeframe trend analysis tool for XAUUSD.
- Traders who rely on trend-following strategies and need confirmation across multiple timeframes.
- Those who prefer a multi-indicator approach to avoid false signals and improve the accuracy of their trades.
Disclaimer
This indicator is for informational and educational purposes only. It is recommended to combine this with proper risk management strategies and your own analysis. Past performance does not guarantee future results. Always perform your own due diligence before making trading decisions.
STANDARD DEVIATION INDICATOR BY WISE TRADERWISE TRADER STANDARD DEVIATION SETUP: The Ultimate Volatility and Trend Analysis Tool
Unlock the power of STANDARD DEVIATIONS like never before with the this indicator, a versatile and comprehensive tool designed for traders who seek deeper insights into market volatility, trend strength, and price action. This advanced indicator simultaneously plots three sets of customizable Deviations, each with unique settings for moving average types, standard deviations, and periods. Whether you’re a swing trader, day trader, or long-term investor, the STANDARD DEVIATION indicator provides a dynamic way to spot potential reversals, breakouts, and trend-following opportunities.
Key Features:
STANDARD DEVIATIONS Configuration : Monitor three different Bollinger Bands at the same time, allowing for multi-timeframe analysis within a single chart.
Customizable Moving Average Types: Choose from SMA, EMA, SMMA (RMA), WMA, and VWMA to calculate the basis of each band according to your preferred method.
Dynamic Standard Deviations: Set different standard deviation multipliers for each band to fine-tune sensitivity for various market conditions.
Visual Clarity: Color-coded bands with adjustable thicknesses provide a clear view of upper and lower boundaries, along with fill backgrounds to highlight price ranges effectively.
Enhanced Trend Detection: Identify potential trend continuation, consolidation, or reversal zones based on the position and interaction of price with the three bands.
Offset Adjustment: Shift the bands forward or backward to analyze future or past price movements more effectively.
Why Use Triple STANDARD DEVIATIONS ?
STANDARD DEVIATIONS are a popular choice among traders for measuring volatility and anticipating potential price movements. This indicator takes STANDARD DEVIATIONS to the next level by allowing you to customize and analyze three distinct bands simultaneously, providing an unparalleled view of market dynamics. Use it to:
Spot Volatility Expansion and Contraction: Track periods of high and low volatility as prices move toward or away from the bands.
Identify Overbought or Oversold Conditions: Monitor when prices reach extreme levels compared to historical volatility to gauge potential reversal points.
Validate Breakouts: Confirm the strength of a breakout when prices move beyond the outer bands.
Optimize Risk Management: Enhance your strategy's risk-reward ratio by dynamically adjusting stop-loss and take-profit levels based on band positions.
Ideal For:
Forex, Stocks, Cryptocurrencies, and Commodities Traders looking to enhance their technical analysis.
Scalpers and Day Traders who need rapid insights into market conditions.
Swing Traders and Long-Term Investors seeking to confirm entry and exit points.
Trend Followers and Mean Reversion Traders interested in combining both strategies for maximum profitability.
Harness the full potential of STANDARD DEVIATIONS with this multi-dimensional approach. The "STANDARD DEVIATIONS " indicator by WISE TRADER will become an essential part of your trading arsenal, helping you make more informed decisions, reduce risks, and seize profitable opportunities.
Who is WISE TRADER ?
Wise Trader is a highly skilled trader who launched his channel in 2020 during the COVID-19 pandemic, quickly building a loyal following. With thousands of paid subscribed members and over 70,000 YouTube subscribers, Wise Trader has become a trusted authority in the trading world. He is known for his ability to navigate significant events, such as the Indian elections and stock market crashes, providing his audience with valuable insights into market movements and volatility. With a deep understanding of macroeconomics and its correlation to global stock markets, Wise Trader shares informed strategies that help traders make better decisions. His content covers technical analysis, trading setups, economic indicators, and market trends, offering a comprehensive approach to understanding financial markets. The channel serves as a go-to resource for traders who want to enhance their skills and stay informed about key market developments.
Distance between EMA 50-100/100-150This script calculates and plots the percentage difference between the 50-period, 100-period, and 150-period Exponential Moving Averages (EMA) on a TradingView chart. The aim is to provide a clear visual representation of the market's momentum by analyzing the distance between key EMAs over time.
Key features of this script:
1. EMA Calculation : The script computes the EMA values for 50, 100, and 150 periods and calculates the percentage difference between EMA 50 and 100, and between EMA 100 and 150.
2. Custom Threshold : Users can adjust a threshold percentage to highlight significant divergences between the EMAs. A default threshold is set to 0.1%.
3. Visual Alerts : When the percentage difference exceeds the threshold, a visual marker appears on the chart:
Green Circles for bullish momentum (positive divergence),
Red Circles for bearish momentum (negative divergence),
Diamonds to indicate the first occurrence of new bullish or bearish signals, allowing users to catch fresh market trends.
4. Dynamic Plotting : The script plots two lines representing the percentage difference for each EMA pair, offering a quick and intuitive way to monitor trends.
Ideal for traders looking to gauge market direction using the relationship between multiple EMAs, this script simplifies analysis by focusing on key moving average interactions.
Hide Days"Hide Days" Pine Script Indicator
The "Hide Days" indicator is designed to make specific days of the week less visible by altering the candle colors, making them blend into the background. This can help traders focus on specific trading days by hiding unwanted candles from view.
Features:
Selectable Days: Users can choose which days of the week to hide (Sunday through Saturday).
Dark Mode Toggle: A built-in "Dark Mode" option provides an optimized display based on the user's TradingView theme, setting hidden candles to a nearly invisible color that matches the background.
Dark Mode ON: Candles are set to dark gray (#151924).
Dark Mode OFF: Candles are set to white (#ffffff).
Simple Inputs: The indicator provides checkboxes for each day, making customization quick and easy.
Enhanced Focus: Useful for traders who want to focus on specific trading sessions or eliminate less relevant days from their chart view.
Use Cases:
Hide weekend data on charts to focus on weekdays.
Remove non-trading days to analyze market movements more effectively.
Adjust the indicator to blend with either dark or light chart themes.
RSI Weighted Trend System I [InvestorUnknown]The RSI Weighted Trend System I is an experimental indicator designed to combine both slow-moving trend indicators for stable trend identification and fast-moving indicators to capture potential major turning points in the market. The novelty of this system lies in the dynamic weighting mechanism, where fast indicators receive weight based on the current Relative Strength Index (RSI) value, thus providing a flexible tool for traders seeking to adapt their strategies to varying market conditions.
Dynamic RSI-Based Weighting System
The core of the indicator is the dynamic weighting of fast indicators based on the value of the RSI. In essence, the higher the absolute value of the RSI (whether positive or negative), the higher the weight assigned to the fast indicators. This enables the system to capture rapid price movements around potential turning points.
Users can choose between a threshold-based or continuous weight system:
Threshold-Based Weighting: Fast indicators are activated only when the absolute RSI value exceeds a user-defined threshold. Below this threshold, fast indicators receive no weight.
Continuous Weighting: By setting the weight threshold to zero, the fast indicators always receive some weight, although this can result in more false signals in ranging markets.
// Calculate weight for Fast Indicators based on RSI (Slow Indicator weight is kept to 1 for simplicity)
f_RSI_Weight_System(series float rsi, simple float weight_thre) =>
float fast_weight = na
float slow_weight = na
if weight_thre > 0
if math.abs(rsi) <= weight_thre
fast_weight := 0
slow_weight := 1
else
fast_weight := 0 + math.sqrt(math.abs(rsi))
slow_weight := 1
else
fast_weight := 0 + math.sqrt(math.abs(rsi))
slow_weight := 1
Slow and Fast Indicators
Slow Indicators are designed to identify stable trends, remaining constant in weight. These include:
DMI (Directional Movement Index) For Loop
CCI (Commodity Channel Index) For Loop
Aroon For Loop
Fast Indicators are more responsive and designed to spot rapid trend shifts:
ZLEMA (Zero-Lag Exponential Moving Average) For Loop
IIRF (Infinite Impulse Response Filter) For Loop
Each of these indicators is calculated using a for-loop method to generate a moving average, which captures the trend of a given length range.
RSI Normalization
To facilitate the weighting system, the RSI is normalized from its usual 0-100 range to a -1 to 1 range. This allows for easy scaling when calculating weights and helps the system adjust to rapidly changing market conditions.
// Normalize RSI (1 to -1)
f_RSI(series float rsi_src, simple int rsi_len, simple string rsi_wb, simple string ma_type, simple int ma_len) =>
output = switch rsi_wb
"RAW RSI" => ta.rsi(rsi_src, rsi_len)
"RSI MA" => ma_type == "EMA" ? (ta.ema(ta.rsi(rsi_src, rsi_len), ma_len)) : (ta.sma(ta.rsi(rsi_src, rsi_len), ma_len))
Signal Calculation
The final trading signal is a weighted average of both the slow and fast indicators, depending on the calculated weights from the RSI. This ensures a balanced approach, where slow indicators maintain overall trend guidance, while fast indicators provide timely entries and exits.
// Calculate Signal (as weighted average)
sig = math.round(((DMI*slow_w) + (CCI*slow_w) + (Aroon*slow_w) + (ZLEMA*fast_w) + (IIRF*fast_w)) / (3*slow_w + 2*fast_w), 2)
Backtest Mode and Performance Metrics
This version of the RSI Weighted Trend System includes a comprehensive backtesting mode, allowing users to evaluate the performance of their selected settings against a Buy & Hold strategy. The backtesting includes:
Equity calculation based on the signals generated by the indicator.
Performance metrics table comparing Buy & Hold strategy metrics with the system’s signals, including: Mean, positive, and negative return percentages, Standard deviations (of all, positive and negative returns), Sharpe Ratio, Sortino Ratio, and Omega Ratio
f_PerformanceMetrics(series float base, int Lookback, simple float startDate, bool Annualize = true) =>
// Initialize variables for positive and negative returns
pos_sum = 0.0
neg_sum = 0.0
pos_count = 0
neg_count = 0
returns_sum = 0.0
returns_squared_sum = 0.0
pos_returns_squared_sum = 0.0
neg_returns_squared_sum = 0.0
// Loop through the past 'Lookback' bars to calculate sums and counts
if (time >= startDate)
for i = 0 to Lookback - 1
r = (base - base ) / base
returns_sum += r
returns_squared_sum += r * r
if r > 0
pos_sum += r
pos_count += 1
pos_returns_squared_sum += r * r
if r < 0
neg_sum += r
neg_count += 1
neg_returns_squared_sum += r * r
float export_array = array.new_float(12)
// Calculate means
mean_all = math.round((returns_sum / Lookback) * 100, 2)
mean_pos = math.round((pos_count != 0 ? pos_sum / pos_count : na) * 100, 2)
mean_neg = math.round((neg_count != 0 ? neg_sum / neg_count : na) * 100, 2)
// Calculate standard deviations
stddev_all = math.round((math.sqrt((returns_squared_sum - (returns_sum * returns_sum) / Lookback) / Lookback)) * 100, 2)
stddev_pos = math.round((pos_count != 0 ? math.sqrt((pos_returns_squared_sum - (pos_sum * pos_sum) / pos_count) / pos_count) : na) * 100, 2)
stddev_neg = math.round((neg_count != 0 ? math.sqrt((neg_returns_squared_sum - (neg_sum * neg_sum) / neg_count) / neg_count) : na) * 100, 2)
// Calculate probabilities
prob_pos = math.round((pos_count / Lookback) * 100, 2)
prob_neg = math.round((neg_count / Lookback) * 100, 2)
prob_neu = math.round(((Lookback - pos_count - neg_count) / Lookback) * 100, 2)
// Calculate ratios
sharpe_ratio = math.round(mean_all / stddev_all * (Annualize ? math.sqrt(Lookback) : 1), 2)
sortino_ratio = math.round(mean_all / stddev_neg * (Annualize ? math.sqrt(Lookback) : 1), 2)
omega_ratio = math.round(pos_sum / math.abs(neg_sum), 2)
// Set values in the array
array.set(export_array, 0, mean_all), array.set(export_array, 1, mean_pos), array.set(export_array, 2, mean_neg),
array.set(export_array, 3, stddev_all), array.set(export_array, 4, stddev_pos), array.set(export_array, 5, stddev_neg),
array.set(export_array, 6, prob_pos), array.set(export_array, 7, prob_neu), array.set(export_array, 8, prob_neg),
array.set(export_array, 9, sharpe_ratio), array.set(export_array, 10, sortino_ratio), array.set(export_array, 11, omega_ratio)
// Export the array
export_array
The metrics help traders assess the effectiveness of their strategy over time and can be used to optimize their settings.
Calibration Mode
A calibration mode is included to assist users in tuning the indicator to their specific needs. In this mode, traders can focus on a specific indicator (e.g., DMI, CCI, Aroon, ZLEMA, IIRF, or RSI) and fine-tune it without interference from other signals.
The calibration plot visualizes the chosen indicator's performance against a zero line, making it easy to see how changes in the indicator’s settings affect its trend detection.
Customization and Default Settings
Important Note: The default settings provided are not optimized for any particular market or asset. They serve as a starting point for experimentation. Traders are encouraged to calibrate the system to suit their own trading strategies and preferences.
The indicator allows deep customization, from selecting which indicators to use, adjusting the lengths of each indicator, smoothing parameters, and the RSI weight system.
Alerts
Traders can set alerts for both long and short signals when the indicator flips, allowing for automated monitoring of potential trading opportunities.
Normalized Linear Regression (LSMA) OscillatorNormalized Linear Regression (LSMA) Oscillator
By Nathan Farmer
The Normalized LSMA Oscillator is a trend-following indicator that enhances the classic Linear Regression (LSMA) by applying a range of normalization techniques. This indicator allows traders to smooth out and normalize LSMA signals for better trend detection and dynamic market adaptation.
Key Features:
Configurable Normalization Methods:
This indicator offers several normalization techniques, such as Z-Score, Min-Max, Mean Normalization, Robust Scaler, Logistic Function, and Quantile Transformation. Each method helps in refining LSMA outputs to improve clarity in both trending and ranging market conditions.
Smoothing Options:
Smoothing can be applied after normalization, helping to reduce noise in the signals, thus making trend-following strategies that use this indicator more effective.
Recommended Settings:
Logistic Function Normalization: Recommended length of around 12, based on my preferred signal frequency.
Z-Score Normalization: Medium period (close to the default of 50), based on my preferred signal frequency.
Min-Max Normalization: Medium period, based on my preferred signal frequency.
Mean Normalization: Medium period, based on my preferred signal frequency.
Robust Scaler: Medium period, based on my preferred signal frequency.
Quantile Transformation: Medium period, based on my preferred signal frequency.
Usage:
Designed primarily for trend-following strategies, this indicator adapts well to varying market conditions. Traders can experiment with the various normalization and smoothing settings to match the indicator to their specific needs and market preferences.
Recommendation before usage:
Always backtest the indicator for yourself with respect to how you intend to use it. Modify the parameters to suit your needs, over your preferred time frame, on your preferred asset. My preferences are for the assets I happened to be looking at when I made this indicator. Odds are, you're looking at something else, over a different time frame, in a different market environment than what my settings are tailored for.