Bli-Rik (Buy and sell based on RSI & SMA)Basis analysis of Stoch RSI + RSI + 34/200 SMA Signals we have identified and generated Buy and sell indication on chart, This will help to guild buy and sell process...
Indikatoren und Strategien
SNP420/TRCS_MASTERMicro Body Candle Highlighter is a visual tool for TradingView that continuously scans the active timeframe and highlights all candles with an extremely small body.
For every bar (including the currently forming one), the indicator compares the absolute distance between Open and Close to a user-defined threshold in ticks (default: 1 tick, based on syminfo.mintick).
If the candle’s body size is less than or equal to this threshold, the indicator draws a red frame around the candle – either around the body only or the full high-to-low range, depending on user settings.
Optionally, the indicator can also trigger alerts whenever such a “micro body” candle is detected, allowing traders to react immediately to potential indecision, pauses, or micro-reversals in price action.
author: SNP_420
project: FNXS
ps: Piece and love
8am H1 High/LowThis indicator labels and produces horizontal lines indicating 1 hour liquidity levels.
價漲量增 + 力度 + 艾爾德 精簡版這是一套結合三大核心邏輯的多維強勢趨勢偵測系統:
PUVU 價漲量增:確認價格突破是否具備真實量能。
Strength 力度指標:整合 ROC、RSI 斜率、MACD 動能三項數據,轉換為 0–100 的標準化強度分數。
Elder Impulse System:以視覺化 K 棒顏色呈現趨勢動能變化。
此外,本工具加入 Trend Bias 趨勢偏向濾網、極端反手模式、精準信號三角形與可視化面板,
可用於判斷市場是否具備持續性動能、突破是否可信、反轉是否具備條件。
本指標適用於:
趨勢交易
波段突破
盤整突破偵測
高勝率強勢區辨識
多品種分析(加密貨幣、外匯、指數、股票)
此版本可用於觀察趨勢方向、尋找可能的交易機會與賣出時機。
For English users:
This script provides trend analysis, volume confirmation, strength scoring, and impulse-based visualization to assist traders in identifying potential breakouts and market conditions.
Bookmap Style Aggressor Bubbles
This indicator is designed to emulate the visual aesthetic of professional Order Flow software (such as Bookmap) directly within TradingView. It replaces the traditional candlestick view with a clean "Microstructure" Step Line and highlights significant volume events using dynamic "Aggressor Bubbles."
This tool is perfect for traders who practice Order Flow analysis, Scalping, or VSA (Volume Spread Analysis) and want to visualize the relative intensity of buyers and sellers without the noise of traditional wicks and bodies.
1. How it Works
Since TradingView Pine Script operates on OHLCV (Level 1) data, this indicator uses a heuristic model to approximate Order Flow dynamics:
Aggressor Bubbles (Volume Spikes):
The script calculates a Relative Volume (RVOL) metric by comparing the current bar's volume against a 50-period Simple Moving Average (SMA).
If the current volume exceeds a user-defined threshold (e.g., 2.0x the average), a bubble is plotted.
Size: The bubble size scales dynamically based on how massive the volume spike is (Small, Normal, Large, Huge).
Direction (Color): The aggressor side is approximated using the price action of the bar. If Close >= Open, it is treated as Buy Aggression (Green). If Close < Open, it is treated as Sell Aggression (Red).
Microstructure Price Line:
Standard candles can obscure the immediate path of price. This indicator includes a Step Line option that plots the closing price. This mimics the "Last Price" feed seen in DOM-based software, allowing you to see exactly where price held or broke.
2. Features
Smart Filtering: Filters out low-volume noise. You only see bubbles when "Whales" or significant liquidity changes occur.
Visual Customization: Fully adjustable colors for Buy/Sell bubbles and the price line.
Alert System: Includes a built-in alert that triggers whenever a significant Aggressor Bubble appears, allowing you to be notified of high-activity moments instantly.
Clean Aesthetic: Optimized for Dark Mode/Black backgrounds.
3. How to Use
Chart Setup (Important): For the best experience, hide your standard candles. Go to Chart Settings > Symbol and uncheck Body, Borders, and Wick.
Settings: Set your background to Black.
Interpretation:
Breakouts: Look for large bubbles pushing price through a key level. This indicates strong momentum.
Absorptions: Look for large bubbles appearing at the top/bottom of a range without price follow-through. This often suggests a reversal (Passive limit orders absorbing the aggressive market orders).
4. Technical Disclosure & Limitations
Please note that TradingView Pine Script provides access to OHLCV (History) data, not historical Tick-by-Tick or Level 2 (Depth of Market) data. Therefore, this indicator is a simulation. The "Aggressor" side is derived from bar direction, and the bubbles represent executed volume per bar, not individual tick clusters. It is intended for visual analysis and identifying high-volume nodes relative to recent history.
MAT's Equal Highs and Lows IndicatorEqual highs and lows indicator. This is an indicator that marks out equal highs and lows within the market, wich can be a strong draw on liquidity.
Renko ScalperWhat it is-
A lightweight Renko Scalper that combines Renko brick direction with an internal EMA trend filter and MACD confirmation to signal high-probability short-term entries. EMAs are used internally (hidden from the chart) so the visual remains uncluttered.
Signals-
Buy arrow: Renko direction turns bullish AND EMA trend up AND MACD histogram positive.
Sell arrow: Renko direction turns bearish AND EMA trend down AND MACD histogram negative.
Consecutive same-direction signals are suppressed (only one arrow per direction until opposite signal).
Visuals-
Buy / Sell arrows (large) above/below bars.
Chart background tints green/red after the respective signal for easy glance recognition.
Inputs:-
Renko Box Size (points)
EMA Fast / EMA Slow
MACD fast/slow/signal lengths
How to use-
Add to chart
Use smaller Renko box sizes for scalping, larger for swing-like entries.
Confirm signal with price action and volume—this indicator is a signal generator, not a full automated system.
Use alerts (built in) to receive Buy / Sell arrow notifications.
Alerts-
Buy Arrow — buySignal
Sell Arrow — sellSignal
Buy Background / Sell Background — background-color state alerts
Recommended settings-
Timeframes: 1m–15m for scalping, 5m for balanced intraday.
Symbols: liquid futures/currency pairs/major crypto.
Disclaimer
This script is educational and not financial advice. Backtest and forward test on a demo account before live use. Past performance is not indicative of future results. Use proper risk management.
BPR [Gold Group]✨ BPR Indicator – Gold Group
The BPR (Breakout–Pullback–Reversal) Indicator by Gold Group is a premium, research-based market tool designed to help traders identify high-probability trading opportunities with precision. Built on advanced price-action logic and institutional behavior analysis, this indicator highlights key market zones where smart-money activity is most likely to occur—allowing traders to enter the market with confidence and clarity.
🔍 What the BPR Indicator Does
Detects Breakout Zones where liquidity is taken and momentum shifts begin.
Marks Pullback Levels where the market retests institutional footprints.
Identifies Reversal Points with high accuracy for powerful entries.
Filters out market noise, showing only meaningful structure changes.
Works on all timeframes and all major assets such as Gold, Forex, NAS100, US30, Crypto.
🔥 Why This Indicator Is Important
Helps traders understand institutional price movement, not retail traps.
Reduces emotional decision-making by giving crystal-clear levels.
Increases trade accuracy by aligning entries with market structure shifts.
Saves time by automatically plotting areas where smart money reacts.
🎯 Why You Should Use It
Perfect for both beginners and professionals.
Suitable for scalping, intraday, and swing trading.
Developed and tested by Gold Group Research Team with proven performance.
Allows traders to stay ahead of manipulative moves and avoid fake breakouts
Forex Trend Master FollowerThis indicator is based on slow and fast EMA, like regular EMA cross, but updated. It works the best on trendy pairs like EU, and works the best on 4h time frame. It shows where to entry and where to close the position based on slow EMA. It can be used like additional confluence with FTB entry model, and whole strategy.
Daily TQQQ Trend Strategy (Ultra-Discreet Text Signals)✅ TradingView Description (Professional + Clean)
Daily TQQQ Trend Strategy (Ultra-Discreet Text Signals)
This indicator provides clean, minimalistic trend-following signals designed for traders who want confirmation without cluttering the chart.
Instead of using arrows, boxes, or colored shapes, this script prints tiny text labels (“Buy – trend strong” / “Sell – trend weakening”) directly on the price chart. These messages are intentionally discreet so they do not interfere with existing indicators, automated systems, or visually busy setups.
🔍 How It Works
The indicator analyzes the market using three well-established components:
1. Trend Direction (EMA 8 & EMA 20)
• Buy condition: price above both EMAs
• Sell condition: price below both EMAs
2. Momentum Confirmation (MACD)
• Buy: MACD line > Signal line
• Sell: MACD line < Signal line
3. Strength Filter (RSI 14)
• Buy: RSI above 50 (bullish strength)
• Sell: RSI below 50 (weakening momentum)
Only when all conditions align does the indicator print a discreet buy or sell label.
🧭 Signal Types
Buy – trend strong
Appears below the candle when overall trend, momentum, and strength all turn bullish.
Sell – trend weakening
Appears above the candle when trend and momentum show weakness and downside pressure increases.
Traffic Lights - BETA ZONESTraffic Lights - BETA ZONES
Overview
The Traffic Light indicator is a simple, visual tool designed to help traders gauge market bias, trend strength, and momentum at a glance. It displays three rows of colored dots (like a traffic light) in a separate pane below your chart:
• Green: Bullish signal (go/buy bias).
• Red: Bearish signal (stop/sell bias).
• Orange: Neutral or caution (mixed/uncertain conditions).
This indicator combines price action (via EMA positioning), trend direction (via RSI), and momentum expansion (via RSI + MACD histogram) to provide a layered view of the market. When all three rows align as green or red, it generates Buy or Sell labels on the main chart for potential entry signals.
It's non-repainting in its core logic (Row 2 uses delayed RSI comparison to avoid noise), making it reliable for live trading. Best used on trending markets like forex, stocks, or crypto on timeframes from 15M to Daily.
How It Works
The indicator evaluates three independent "rows" of conditions, each represented by a colored dot:
1. Row 1: Price Action Signal (EMA Touch) This row assesses the overall trend bias based on price's position relative to a slow EMA (default: 50-period).
o Green: Price is cleanly above the EMA (bullish bias).
o Red: Price is cleanly below the EMA (bearish bias).
o Orange: Price is "touching" or within a volatility buffer around the EMA (neutral/caution). The "touch zone" is defined by ATR padding, which can be toggled off for a stricter (green/red only) mode.
2. Row 2: Buyers/Sellers Trend (RSI) This row tracks the underlying trend of buyer/seller strength using RSI (default: 14-period on close). To reduce noise and repainting, it uses a delayed comparison (RSI vs. RSI ):
o Green: RSI is rising (buyers gaining strength).
o Red: RSI is falling (sellers gaining strength). No orange here—it's purely directional.
3. Row 3: Buyers/Sellers Signal (RSI + MACD Histogram) This row focuses on momentum expansion, requiring alignment across RSI zones and MACD histogram:
o Green: RSI > 50 (bull zone), MACD hist > 0 (positive), and histogram is expanding upward.
o Red: RSI < 50 (bear zone), MACD hist < 0 (negative), and histogram is expanding downward.
o Orange: Any mismatch (e.g., pullbacks, consolidations, or weak momentum). MACD defaults: Fast=12, Slow=26, Signal=9.
Signals
• Buy Signal: Triggers a "Buy" label below the bar when all three rows turn green for the first time (crossover from non-aligned).
• Sell Signal: Triggers a "Sell" label above the bar when all three rows turn red for the first time. These are conservative signals—use them for trend confirmation or entries in alignment with your strategy. They don't repaint once fired.
Inputs & Customization
All inputs are grouped for easy tweaking:
• Row 1: Price Action Signal
o Slow EMA Length (default: 50): Adjusts the trend baseline.
o EMA Timeframe (default: empty/current): Use a higher timeframe (e.g., "240" for 4H) for multi-timeframe analysis.
o Enable Orange 'Touch' Zone (default: true): Toggle for strict (green/red only) vs. touch mode.
o ATR Length (default: 3): Volatility period for touch padding.
o Touch Padding (ATR mult, default: 0.15): Widens the orange buffer; set to 0 for wick-touch only.
• Row 2: Buyers/Sellers Trend (RSI)
o RSI Length (default: 14): Period for RSI calculation.
o RSI Source (default: close): Change to high/low/open for different sensitivities.
• Row 3: Buyers/Sellers Signal (RSI + MACD hist)
o MACD Fast/Slow/Signal Lengths (defaults: 12/26/9): Standard MACD settings.
Usage Tips
• Trend Trading: Wait for all-green for long entries or all-red for shorts. Use in conjunction with support/resistance.
• Scalping/Intraday: Enable orange touch zone for more nuance in choppy markets; disable for cleaner signals in trends.
• Multi-Timeframe: Set Row 1 EMA to a higher TF for "big picture" bias while keeping others on current.
• Risk Management: Always combine with stop-losses (e.g., below recent lows for buys). Backtest on your asset/timeframe.
• Limitations: In ranging markets, orange dots may dominate—pair with volatility filters like ADX. Not a standalone system; use as a confirmation tool.
If you have feedback or suggestions, drop a comment below! Happy trading 🚦
Prime-Time × Vortex (3/6/9) — Ace (clean v3)1️⃣ Prime-Time Index (PT)
A bar becomes Prime-Time when the count satisfies the formula:
4·n − 3 is a perfect square
This generates the sequence:
1, 3, 7, 13, 21, 31, 43, 57, 73, 91, …
These are time windows where price is more likely to form:
Shifts in market structure
Impulses
Reversals
Liquidity expansions
These PT bars are drawn as small circles above the candle.
If labels are enabled, the counter value (n) is also shown.
2️⃣ Vortex 3/6/9 Digital-Root Timing
Every bar also has a digital root, calculated from the counter:
If n → digitalRoot(n) = 3, 6, or 9,
the bar is considered a Vortex bar.
These moments often align with:
Swing highs / swing lows
Micro shifts
Mini-reversals
Minor liquidity grabs
When a Prime-Time bar is also a 3/6/9 bar → high-probability timing.
These bars are highlighted in green by default.
3️⃣ Filters & Display
You can customize:
Anchor time → when counting begins
Reset daily → restart counter each new trading day
Show only 3/6/9 → hides normal PT hits
Label offset → distance above the candle
Color themes
This makes the indicator usable on:
1Min
5Min
15Min
1H
Any timeframe you want
4️⃣ How To Apply It in Trading
Use it as a time confluence tool, not a signal generator.
✔ Best ways to use:
Look for MSS, sweeps, OB retests, FVG reactions when
they occur on or near a Prime-Time or 3/6/9 bar
Expect volatility increases after PT bars
Use 3/6/9 hits to anticipate internal turning points
Combine with:
Session High/Low
Killzones (London, NYO, PM)
Purge Protocol
MMXM Execution
✔ Example:
If price sweeps a level and prints a 3/6/9 vortex bar inside a PT window →
you have a very strong timing alignment for reversal.
5️⃣ Simple Summary
Feature Meaning
Prime-Time Hit (PT) Major time window where price often shifts
3/6/9 Vortex Bar Micro-timing for internal swings
PT + 3/6/9 together High-probability timing for entries
Reset Daily Perfect for intraday models like NYO & London
Anchor Time Defines the entire cycle structure
Options Gamma Surface 3DOANDA:XAUUSD
Features :
📊 3D Gamma Surface
X-axis: Strike Price
Y-axis: Days to Expiry
Z-axis: Gamma Value
🏔️ Mountain Visualization
Displays the 3D surface of the Gamma value.
The Highest Gamma forms the Peak (mountain top).
Color Gradient based on Gamma height
Grid wireframe displays the structure.
🚩 Flag on Peak Gamma
A flag is planted on the point of Maximum Gamma.
Displays the Strike Price and Days to Expiry for that point.
🏷️ Strike Labels
Displays Strike Prices on the surface.
Strike Prices near ATM (At-The-Money) are colored Gold.
Other Strikes are colored Blue.
📈 Greeks Table (Right Panel)
Displays all Greeks at ATM: Price, Delta, Gamma, Vega, Theta.
Displays Parameters: IV, Days, Risk-Free Rate.
Displays the Peak Gamma point and its value.
⚙️ Customization Options
Options Parameters: Set Strike Range, IV, Days, Risk-Free Rate.
Camera: Rotate the view with Yaw/Pitch, adjust X/Y/Z Scale.
Grid/Surface: Turn On/Off Wireframe, Surface fill.
Color Palette: Select your preferred color theme.
The surface clearly shows where Gamma is highest, which is usually at ATM (At-The-Money) and with intermediate Days to Expiry. This is ideal for Options Traders who want to visualize their Gamma Exposure! 🚀
Gaussian Hidden Markov ModelA Hidden Markov Model (HMM) is a statistical model that assumes an underlying process is a Markov process with unobservable (hidden) states. In the context of financial data analysis, a HMM can be particularly useful because it allows for the modeling of time series data where the state of the market at a given time depends on its state in the previous time period, but these states are not directly observable from the market data. When we say that a state is "unobservable" or "hidden," we mean that the true state of the process generating the observations at any time is not directly visible or measurable. Instead, what is observed is a set of data points that are influenced by these hidden states.
The HMM uses a set of observed data to infer the sequence of hidden states of the model (in our case a model with 3 states and Gaussian emissions). It comprises three main components: the initial probabilities, the state transition probabilities, and the emission probabilities. The initial probabilities describe the likelihood of starting in a particular state. The state transition probabilities describe the likelihood of moving from one state to another, while the emission probabilities (in our case emitted from Gaussian probability density functions, in the image red yellow and green Laplace probability densitty functions) describe the likelihood of the observed data given a particular state.
MODEL FIT
Posterior
By default, the indicator displays the posterior distribution as fitted by training a 3-state Gaussian HMM. The posterior refers to the probability distribution of the hidden states given the observed data. In the case of your Gaussian HMM with three states, the posterior represents the probabilities that the model assigns to each of these three states at each time point, after observing the data. The term "posterior" comes from Bayes' theorem, where it represents the updated belief about the model's states after considering the evidence (the observed data).
In the indicator, the posterior is visualized as the probability of the stock market being in a particular volatility state (high vol, medium vol, low vol) at any given time in the time series. Each day, the probabilities of the three states sum to 1, with the plot showing color-coded bands to reflect these state probabilities over time. It is important to note that the posterior distribution of the model fit tells you about the performance of the model on past data. The model calculates the probabilities of observations for all states by taking into account the relationship between observations and their past and future counterparts in the dataset. This is achieved using the forward-backward algorithm, which enables us to train the HMM.
Conditional Mean
The conditional mean is the expected value of the observed data given the current state of the model. For a Gaussian HMM, this would be the mean of the Gaussian distribution associated with the current state. It’s "conditional" because it depends on the probabilities of the different states the model is in at a given time. This connects back to the posterior probability, which assigns a probability to the model being in a particular state at a given time.
Conditional Standard Deviation Bands
The conditional standard deviation is a measure of the variability of the observed data given the current state of the model. In a Gaussian HMM, each state has its own emission probability, defined by a Gaussian distribution with a specific mean and standard deviation. The standard deviation represents how spread out the data is around the mean for each state. These bands directly relate to the emission probabilities of the HMM, as they describe the likelihood of the observed values given the current state. Narrow bands suggest a lower standard deviation, indicating the model is more confident about the data's expected range when in that state, while wider bands indicate higher uncertainty and variability.
Transition Matrix
The transition matrix in a HMM is a key component that characterizes the model. It's a square matrix representing the probabilities of transitioning from one hidden state to another. Each row of the transition matrix must sum up to 1 since the probabilities of moving from a given state to all possible subsequent states (including staying in the same state) must encompass all possible outcomes.
For example, we can see the following transition probabilities in our model:
Going from state X: to X (0.98), to Y (0.02), to Z (0)
Going from state Y: to X (0.03), to Y (0.96), to Z (0.01)
Going from state Z: to X (0), to Y (0.11), to Z (0.89)
MODEL TEST
When the "Test Out of Sample” option is enabled, the indicator plots models out-of-sample predictions. This is particularly useful for real-time identification of market regimes, ensuring that the model's predictive capability is rigorously tested on unseen data. The indicator displays the out of sample posterior probabilities which are calculated using the forward algorithm. Higher probability for a particular state indicate that the model is predicted a higher likelihood that the market is currently in that state. Evaluating the models performance on unseen data is crucial in understanding how well the model explains data that are not included in its training process.
THF Ultimate AIO Scalper & Trend PRO This is a comprehensive "All-In-One" trading suite designed to identify high-probability setups by combining **Trend Following**, **Price Action (FVG)**, and **Ichimoku Cloud** systems.
The indicator is designed to be "Ready-to-Trade" out of the box, with all major confluence filters active by default. It helps traders avoid false signals by ensuring that momentum, trend, and support/resistance levels are in alignment.
### 🛠️ Key Features & Components:
**1. Trend & Scalp Engine:**
* **Scalp Signals:** Fast EMA crossovers (7/21) for quick entries.
* **Trend Filter:** Signals are filtered by a long-term SMA (200) to ensure you are trading with the dominant trend.
* **Golden/Death Cross:** Automatically highlights major trend shifts (SMA 50 crossing SMA 200).
**2. Price Action (Fair Value Gaps):**
* **FVG Detection:** Highlights unmitigated Bullish and Bearish imbalance zones. These act as high-probability targets or re-entry zones.
* **Dashboard:** A built-in panel tracks the number of active vs. mitigated gaps.
* **Mitigation Lines:** Automatically draws lines when price tests an FVG level.
**3. Ichimoku Cloud Overlay:**
* Displays the full Ichimoku system (Tenkan, Kijun, and Kumo Cloud) to identify dynamic support/resistance and trend strength.
* **Usage:** Perfect for confirming breakout signals when price is above/below the Cloud.
**4. Momentum & Volume:**
* **Volume Coloring:** Bars are colored based on relative volume strength.
* **RSI & MACD:** Integrated buy/sell signals to spot overbought/oversold conditions instantly.
### 🎯 How to Trade (Confluence Strategy):
The power of this script lies in **Confluence** (multiple indicators agreeing):
* **Buy Setup:**
1. Price is above the **Ichimoku Cloud** and **SMA 200**.
2. Wait for a **"SCALP BUY"** signal or **"Trend BUY"** label.
3. Confirm that price is reacting to a **Bullish FVG** (Green Box).
4. **RSI/MACD** should show bullish momentum.
* **Sell Setup:**
1. Price is below the **Ichimoku Cloud** and **SMA 200**.
2. Wait for a **"SCALP SELL"** signal.
3. Confirm rejection from a **Bearish FVG** (Red Box).
---
**CREDITS & ATTRIBUTION:**
* **Fair Value Gap Logic:** This script utilizes the open-source FVG calculation method originally developed by **LuxAlgo**. We have integrated this logic with our custom trend system to provide a complete trading view.
* **Trend Logic:** Custom compilation of Moving Average crossovers and Ichimoku standard calculations.
*Disclaimer: This tool is for educational purposes only. Always manage your risk.*
Hurst Exponent - Detrended Fluctuation AnalysisIn stochastic processes, chaos theory and time series analysis, detrended fluctuation analysis (DFA) is a method for determining the statistical self-affinity of a signal. It is useful for analyzing time series that appear to be long-memory processes and noise.
█ OVERVIEW
We have introduced the concept of Hurst Exponent in our previous open indicator Hurst Exponent (Simple). It is an indicator that measures market state from autocorrelation. However, we apply a more advanced and accurate way to calculate Hurst Exponent rather than simple approximation. Therefore, we recommend using this version of Hurst Exponent over our previous publication going forward. The method we used here is called detrended fluctuation analysis. (For folks that are not interested in the math behind the calculation, feel free to skip to "features" and "how to use" section. However, it is recommended that you read it all to gain a better understanding of the mathematical reasoning).
█ Detrend Fluctuation Analysis
Detrended Fluctuation Analysis was first introduced by by Peng, C.K. (Original Paper) in order to measure the long-range power-law correlations in DNA sequences . DFA measures the scaling-behavior of the second moment-fluctuations, the scaling exponent is a generalization of Hurst exponent.
The traditional way of measuring Hurst exponent is the rescaled range method. However DFA provides the following benefits over the traditional rescaled range method (RS) method:
• Can be applied to non-stationary time series. While asset returns are generally stationary, DFA can measure Hurst more accurately in the instances where they are non-stationary.
• According the the asymptotic distribution value of DFA and RS, the latter usually overestimates Hurst exponent (even after Anis- Llyod correction) resulting in the expected value of RS Hurst being close to 0.54, instead of the 0.5 that it should be. Therefore it's harder to determine the autocorrelation based on the expected value. The expected value is significantly closer to 0.5 making that threshold much more useful, using the DFA method on the Hurst Exponent (HE).
• Lastly, DFA requires lower sample size relative to the RS method. While the RS method generally requires thousands of observations to reduce the variance of HE, DFA only needs a sample size greater than a hundred to accomplish the above mentioned.
█ Calculation
DFA is a modified root-mean-squares (RMS) analysis of a random walk. In short, DFA computes the RMS error of linear fits over progressively larger bins (non-overlapped “boxes” of similar size) of an integrated time series.
Our signal time series is the log returns. First we subtract the mean from the log return to calculate the demeaned returns. Then, we calculate the cumulative sum of demeaned returns resulting in the cumulative sum being mean centered and we can use the DFA method on this. The subtraction of the mean eliminates the “global trend” of the signal. The advantage of applying scaling analysis to the signal profile instead of the signal, allows the original signal to be non-stationary when needed. (For example, this process converts an i.i.d. white noise process into a random walk.)
We slice the cumulative sum into windows of equal space and run linear regression on each window to measure the linear trend. After we conduct each linear regression. We detrend the series by deducting the linear regression line from the cumulative sum in each windows. The fluctuation is the difference between cumulative sum and regression.
We use different windows sizes on the same cumulative sum series. The window sizes scales are log spaced. Eg: powers of 2, 2,4,8,16... This is where the scale free measurements come in, how we measure the fractal nature and self similarity of the time series, as well as how the well smaller scale represent the larger scale.
As the window size decreases, we uses more regression lines to measure the trend. Therefore, the fitness of regression should be better with smaller fluctuation. It allows one to zoom into the “picture” to see the details. The linear regression is like rulers. If you use more rulers to measure the smaller scale details you will get a more precise measurement.
The exponent we are measuring here is to determine the relationship between the window size and fitness of regression (the rate of change). The more complex the time series are the more it will depend on decreasing window sizes (using more linear regression lines to measure). The less complex or the more trend in the time series, it will depend less. The fitness is calculated by the average of root mean square errors (RMS) of regression from each window.
Root mean Square error is calculated by square root of the sum of the difference between cumulative sum and regression. The following chart displays average RMS of different window sizes. As the chart shows, values for smaller window sizes shows more details due to higher complexity of measurements.
The last step is to measure the exponent. In order to measure the power law exponent. We measure the slope on the log-log plot chart. The x axis is the log of the size of windows, the y axis is the log of the average RMS. We run a linear regression through the plotted points. The slope of regression is the exponent. It's easy to see the relationship between RMS and window size on the chart. Larger RMS equals less fitness of the regression. We know the RMS will increase (fitness will decrease) as we increases window size (use less regressions to measure), we focus on the rate of RMS increasing (how fast) as window size increases.
If the slope is < 0.5, It means the rate of of increase in RMS is small when window size increases. Therefore the fit is much better when it's measured by a large number of linear regression lines. So the series is more complex. (Mean reversion, negative autocorrelation).
If the slope is > 0.5, It means the rate of increase in RMS is larger when window sizes increases. Therefore even when window size is large, the larger trend can be measured well by a small number of regression lines. Therefore the series has a trend with positive autocorrelation.
If the slope = 0.5, It means the series follows a random walk.
█ FEATURES
• Sample Size is the lookback period for calculation. Even though DFA requires a lower sample size than RS, a sample size larger > 50 is recommended for accurate measurement.
• When a larger sample size is used (for example = 1000 lookback length), the loading speed may be slower due to a longer calculation. Date Range is used to limit numbers of historical calculation bars. When loading speed is too slow, change the data range "all" into numbers of weeks/days/hours to reduce loading time. (Credit to allanster)
• “show filter” option applies a smoothing moving average to smooth the exponent.
• Log scale is my work around for dynamic log space scaling. Traditionally the smallest log space for bars is power of 2. It requires at least 10 points for an accurate regression, resulting in the minimum lookback to be 1024. I made some changes to round the fractional log space into integer bars requiring the said log space to be less than 2.
• For a more accurate calculation a larger "Base Scale" and "Max Scale" should be selected. However, when the sample size is small, a larger value would cause issues. Therefore, a general rule to be followed is: A larger "Base Scale" and "Max Scale" should be selected for a larger the sample size. It is recommended for the user to try and choose a larger scale if increasing the value doesn't cause issues.
The following chart shows the change in value using various scales. As shown, sometimes increasing the value makes the value itself messy and overshoot.
When using the lowest scale (4,2), the value seems stable. When we increase the scale to (8,2), the value is still alright. However, when we increase it to (8,4), it begins to look messy. And when we increase it to (16,4), it starts overshooting. Therefore, (8,2) seems to be optimal for our use.
█ How to Use
Similar to Hurst Exponent (Simple). 0.5 is a level for determine long term memory.
• In the efficient market hypothesis, market follows a random walk and Hurst exponent should be 0.5. When Hurst Exponent is significantly different from 0.5, the market is inefficient.
• When Hurst Exponent is > 0.5. Positive Autocorrelation. Market is Trending. Positive returns tend to be followed by positive returns and vice versa.
• Hurst Exponent is < 0.5. Negative Autocorrelation. Market is Mean reverting. Positive returns trends to follow by negative return and vice versa.
However, we can't really tell if the Hurst exponent value is generated by random chance by only looking at the 0.5 level. Even if we measure a pure random walk, the Hurst Exponent will never be exactly 0.5, it will be close like 0.506 but not equal to 0.5. That's why we need a level to tell us if Hurst Exponent is significant.
So we also computed the 95% confidence interval according to Monte Carlo simulation. The confidence level adjusts itself by sample size. When Hurst Exponent is above the top or below the bottom confidence level, the value of Hurst exponent has statistical significance. The efficient market hypothesis is rejected and market has significant inefficiency.
The state of market is painted in different color as the following chart shows. The users can also tell the state from the table displayed on the right.
An important point is that Hurst Value only represents the market state according to the past value measurement. Which means it only tells you the market state now and in the past. If Hurst Exponent on sample size 100 shows significant trend, it means according to the past 100 bars, the market is trending significantly. It doesn't mean the market will continue to trend. It's not forecasting market state in the future.
However, this is also another way to use it. The market is not always random and it is not always inefficient, the state switches around from time to time. But there's one pattern, when the market stays inefficient for too long, the market participants see this and will try to take advantage of it. Therefore, the inefficiency will be traded away. That's why Hurst exponent won't stay in significant trend or mean reversion too long. When it's significant the market participants see that as well and the market adjusts itself back to normal.
The Hurst Exponent can be used as a mean reverting oscillator itself. In a liquid market, the value tends to return back inside the confidence interval after significant moves(In smaller markets, it could stay inefficient for a long time). So when Hurst Exponent shows significant values, the market has just entered significant trend or mean reversion state. However, when it stays outside of confidence interval for too long, it would suggest the market might be closer to the end of trend or mean reversion instead.
Larger sample size makes the Hurst Exponent Statistics more reliable. Therefore, if the user want to know if long term memory exist in general on the selected ticker, they can use a large sample size and maximize the log scale. Eg: 1024 sample size, scale (16,4).
Following Chart is Bitcoin on Daily timeframe with 1024 lookback. It suggests the market for bitcoin tends to have long term memory in general. It generally has significant trend and is more inefficient at it's early stage.
Weekly False Breakdown ScannerWeekly False Breakdown Scanner Weekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown ScannerWeekly False Breakdown Scanner
Fast Autocorrelation Estimator█ Overview:
The Fast ACF and PACF Estimation indicator efficiently calculates the autocorrelation function (ACF) and partial autocorrelation function (PACF) using an online implementation. It helps traders identify patterns and relationships in financial time series data, enabling them to optimize their trading strategies and make better-informed decisions in the markets.
█ Concepts:
Autocorrelation, also known as serial correlation, is the correlation of a signal with a delayed copy of itself as a function of delay.
This indicator displays autocorrelation based on lag number. The autocorrelation is not displayed based over time on the x-axis. It's based on the lag number which ranges from 1 to 30. The calculations can be done with "Log Returns", "Absolute Log Returns" or "Original Source" (the price of the asset displayed on the chart).
When calculating autocorrelation, the resulting value will range from +1 to -1, in line with the traditional correlation statistic. An autocorrelation of +1 represents a perfect correlation (an increase seen in one time series leads to a proportionate increase in the other time series). An autocorrelation of -1, on the other hand, represents a perfect inverse correlation (an increase seen in one time series results in a proportionate decrease in the other time series). Lag number indicates which historical data point is autocorrelated. For example, if lag 3 shows significant autocorrelation, it means current data is influenced by the data three bars ago.
The Fast Online Estimation of ACF and PACF Indicator is a powerful tool for analyzing the linear relationship between a time series and its lagged values in TradingView. The indicator implements an online estimation of the Autocorrelation Function (ACF) and the Partial Autocorrelation Function (PACF) up to 30 lags, providing a real-time assessment of the underlying dependencies in your time series data. The Autocorrelation Function (ACF) measures the linear relationship between a time series and its lagged values, capturing both direct and indirect dependencies. The Partial Autocorrelation Function (PACF) isolates the direct dependency between the time series and a specific lag while removing the effect of any indirect dependencies.
This distinction is crucial in understanding the underlying relationships in time series data and making more informed decisions based on those relationships. For example, let's consider a time series with three variables: A, B, and C. Suppose that A has a direct relationship with B, B has a direct relationship with C, but A and C do not have a direct relationship. The ACF between A and C will capture the indirect relationship between them through B, while the PACF will show no significant relationship between A and C, as it accounts for the indirect dependency through B. Meaning that when ACF is significant at for lag 5, the dependency detected could be caused by an observation that came in between, and PACF accounts for that. This indicator leverages the Fast Moments algorithm to efficiently calculate autocorrelations, making it ideal for analyzing large datasets or real-time data streams. By using the Fast Moments algorithm, the indicator can quickly update ACF and PACF values as new data points arrive, reducing the computational load and ensuring timely analysis. The PACF is derived from the ACF using the Durbin-Levinson algorithm, which helps in isolating the direct dependency between a time series and its lagged values, excluding the influence of other intermediate lags.
█ How to Use the Indicator:
Interpreting autocorrelation values can provide valuable insights into the market behavior and potential trading strategies.
When applying autocorrelation to log returns, and a specific lag shows a high positive autocorrelation, it suggests that the time series tends to move in the same direction over that lag period. In this case, a trader might consider using a momentum-based strategy to capitalize on the continuation of the current trend. On the other hand, if a specific lag shows a high negative autocorrelation, it indicates that the time series tends to reverse its direction over that lag period. In this situation, a trader might consider using a mean-reversion strategy to take advantage of the expected reversal in the market.
ACF of log returns:
Absolute returns are often used to as a measure of volatility. There is usually significant positive autocorrelation in absolute returns. We will often see an exponential decay of autocorrelation in volatility. This means that current volatility is dependent on historical volatility and the effect slowly dies off as the lag increases. This effect shows the property of "volatility clustering". Which means large changes tend to be followed by large changes, of either sign, and small changes tend to be followed by small changes.
ACF of absolute log returns:
Autocorrelation in price is always significantly positive and has an exponential decay. This predictably positive and relatively large value makes the autocorrelation of price (not returns) generally less useful.
ACF of price:
█ Significance:
The significance of a correlation metric tells us whether we should pay attention to it. In this script, we use 95% confidence interval bands that adjust to the size of the sample. If the observed correlation at a specific lag falls within the confidence interval, we consider it not significant and the data to be random or IID (identically and independently distributed). This means that we can't confidently say that the correlation reflects a real relationship, rather than just random chance. However, if the correlation is outside of the confidence interval, we can state with 95% confidence that there is an association between the lagged values. In other words, the correlation is likely to reflect a meaningful relationship between the variables, rather than a coincidence. A significant difference in either ACF or PACF can provide insights into the underlying structure of the time series data and suggest potential strategies for traders. By understanding these complex patterns, traders can better tailor their strategies to capitalize on the observed dependencies in the data, which can lead to improved decision-making in the financial markets.
Significant ACF but not significant PACF: This might indicate the presence of a moving average (MA) component in the time series. A moving average component is a pattern where the current value of the time series is influenced by a weighted average of past values. In this case, the ACF would show significant correlations over several lags, while the PACF would show significance only at the first few lags and then quickly decay.
Significant PACF but not significant ACF: This might indicate the presence of an autoregressive (AR) component in the time series. An autoregressive component is a pattern where the current value of the time series is influenced by a linear combination of past values at specific lags.
Often we find both significant ACF and PACF, in that scenario simply and AR or MA model might not be sufficient and a more complex model such as ARMA or ARIMA can be used.
█ Features:
Source selection: User can choose either 'Log Returns' , 'Absolute Returns' or 'Original Source' for the input data.
Autocorrelation Selection: User can choose either 'ACF' or 'PACF' for the plot selection.
Plot Selection: User can choose either 'Autocorrelarrogram' or 'Historical Autocorrelation' for plotting the historical autocorrelation at a specified lag.
Max Lag: User can select the maximum number of lags to plot.
Precision: User can set the number of decimal points to display in the plot.
Chandelier Exit + Pivots + MA + Swing High/LowIt combines four indicators.
For use in the Hero course.
EMA/SMA 350 & 111 (Day Settings) by JayEMA/SMA 350 & 111 (Day Settings) by J
Übergeordneter Trendwechsel erkennen auf High Time Frames
Expected Move BandsExpected move is the amount that an asset is predicted to increase or decrease from its current price, based on the current levels of volatility.
In this model, we assume asset price follows a log-normal distribution and the log return follows a normal distribution.
Note: Normal distribution is just an assumption, it's not the real distribution of return
Settings:
"Estimation Period Selection" is for selecting the period we want to construct the prediction interval.
For "Current Bar", the interval is calculated based on the data of the previous bar close. Therefore changes in the current price will have little effect on the range. What current bar means is that the estimated range is for when this bar close. E.g., If the Timeframe on 4 hours and 1 hour has passed, the interval is for how much time this bar has left, in this case, 3 hours.
For "Future Bars", the interval is calculated based on the current close. Therefore the range will be very much affected by the change in the current price. If the current price moves up, the range will also move up, vice versa. Future Bars is estimating the range for the period at least one bar ahead.
There are also other source selections based on high low.
Time setting is used when "Future Bars" is chosen for the period. The value in time means how many bars ahead of the current bar the range is estimating. When time = 1, it means the interval is constructing for 1 bar head. E.g., If the timeframe is on 4 hours, then it's estimating the next 4 hours range no matter how much time has passed in the current bar.
Note: It's probably better to use "probability cone" for visual presentation when time > 1
Volatility Models :
Sample SD: traditional sample standard deviation, most commonly used, use (n-1) period to adjust the bias
Parkinson: Uses High/ Low to estimate volatility, assumes continuous no gap, zero mean no drift, 5 times more efficient than Close to Close
Garman Klass: Uses OHLC volatility, zero drift, no jumps, about 7 times more efficient
Yangzhang Garman Klass Extension: Added jump calculation in Garman Klass, has the same value as Garman Klass on markets with no gaps.
about 8 x efficient
Rogers: Uses OHLC, Assume non-zero mean volatility, handles drift, does not handle jump 8 x efficient
EWMA: Exponentially Weighted Volatility. Weight recently volatility more, more reactive volatility better in taking account of volatility autocorrelation and cluster.
YangZhang: Uses OHLC, combines Rogers and Garmand Klass, handles both drift and jump, 14 times efficient, alpha is the constant to weight rogers volatility to minimize variance.
Median absolute deviation: It's a more direct way of measuring volatility. It measures volatility without using Standard deviation. The MAD used here is adjusted to be an unbiased estimator.
Volatility Period is the sample size for variance estimation. A longer period makes the estimation range more stable less reactive to recent price. Distribution is more significant on a larger sample size. A short period makes the range more responsive to recent price. Might be better for high volatility clusters.
Standard deviations:
Standard Deviation One shows the estimated range where the closing price will be about 68% of the time.
Standard Deviation two shows the estimated range where the closing price will be about 95% of the time.
Standard Deviation three shows the estimated range where the closing price will be about 99.7% of the time.
Note: All these probabilities are based on the normal distribution assumption for returns. It's the estimated probability, not the actual probability.
Manually Entered Standard Deviation shows the range of any entered standard deviation. The probability of that range will be presented on the panel.
People usually assume the mean of returns to be zero. To be more accurate, we can consider the drift in price from calculating the geometric mean of returns. Drift happens in the long run, so short lookback periods are not recommended. Assuming zero mean is recommended when time is not greater than 1.
When we are estimating the future range for time > 1, we typically assume constant volatility and the returns to be independent and identically distributed. We scale the volatility in term of time to get future range. However, when there's autocorrelation in returns( when returns are not independent), the assumption fails to take account of this effect. Volatility scaled with autocorrelation is required when returns are not iid. We use an AR(1) model to scale the first-order autocorrelation to adjust the effect. Returns typically don't have significant autocorrelation. Adjustment for autocorrelation is not usually needed. A long length is recommended in Autocorrelation calculation.
Note: The significance of autocorrelation can be checked on an ACF indicator.
ACF
The multimeframe option enables people to use higher period expected move on the lower time frame. People should only use time frame higher than the current time frame for the input. An error warning will appear when input Tf is lower. The input format is multiplier * time unit. E.g. : 1D
Unit: M for months, W for Weeks, D for Days, integers with no unit for minutes (E.g. 240 = 240 minutes). S for Seconds.
Smoothing option is using a filter to smooth out the range. The filter used here is John Ehler's supersmoother. It's an advance smoothing technique that gets rid of aliasing noise. It affects is similar to a simple moving average with half the lookback length but smoother and has less lag.
Note: The range here after smooth no long represent the probability
Panel positions can be adjusted in the settings.
X position adjusts the horizontal position of the panel. Higher X moves panel to the right and lower X moves panel to the left.
Y position adjusts the vertical position of the panel. Higher Y moves panel up and lower Y moves panel down.
Step line display changes the style of the bands from line to step line. Step line is recommended because it gets rid of the directional bias of slope of expected move when displaying the bands.
Warnings:
People should not blindly trust the probability. They should be aware of the risk evolves by using the normal distribution assumption. The real return has skewness and high kurtosis. While skewness is not very significant, the high kurtosis should be noticed. The Real returns have much fatter tails than the normal distribution, which also makes the peak higher. This property makes the tail ranges such as range more than 2SD highly underestimate the actual range and the body such as 1 SD slightly overestimate the actual range. For ranges more than 2SD, people shouldn't trust them. They should beware of extreme events in the tails.
Different volatility models provide different properties if people are interested in the accuracy and the fit of expected move, they can try expected move occurrence indicator. (The result also demonstrate the previous point about the drawback of using normal distribution assumption).
Expected move Occurrence Test
The prediction interval is only for the closing price, not wicks. It only estimates the probability of the price closing at this level, not in between. E.g., If 1 SD range is 100 - 200, the price can go to 80 or 230 intrabar, but if the bar close within 100 - 200 in the end. It's still considered a 68% one standard deviation move.
Multi-Timeframe RSI Table (Movable) by AKIt as a Multi Time Frame RSI (Movable) by AK
It has RSI value from 5 min to 1 month timeframe.
Green indicates RSI above 60 - Yellow indicates RSI Below 40
Support & Resistance + VolumeThis script is an advanced technical analysis tool designed to automatically identify institutional Support and Resistance zones, while analyzing the activity (Volume) within these zones. It automatically cleans up the chart to keep only relevant information.
Key Features:
Automatic Zone Detection:
Supports (Green): Identified based on major swing lows (Pivots).
Resistances (Red): Identified based on major swing highs (Pivots).
The width of the zones automatically adapts to market volatility (based on ATR) to remain relevant regardless of the timeframe.
Smart Merging:
To avoid cluttering the chart with overlapping lines, the script detects if a new support or resistance forms within an existing zone.
If so, it does not create a new box but expands the existing zone. This allows you to visualize consolidated "liquidity zones" rather than scattered lines.
Cumulative Volume Profile:
This is the core strength of this indicator. It calculates the total volume traded inside each zone since its creation.
Every time price revisits a zone, the candle's volume is added to the total.
Display: Volume is shown as whole numbers with a $ symbol (e.g., 300 500$) for precise reading.
Interpretation: A zone with very high volume indicates a strong battle between buyers and sellers, making the zone harder to break.
Historical Management (Broken Zones):
If the price crosses and closes beyond a zone (valid breakout), the zone changes appearance immediately.
It turns Gray, stops extending to the right, and the label displays the text "Cassé" (Broken). This allows you to keep a visual trace of past key levels without disturbing current analysis.






















