RawCuts_01Library "RawCuts_01"
A collection of functions by:
mutantdog
The majority of these are used within published projects, some useful variants have been included here aswell.
This is volume one consisting mainly of smaller functions, predominantly the filters and standard deviations from Weight Gain 4000.
Also included at the bottom are various snippets of related code for demonstration. These can be copied and adjusted according to your needs.
A full up-to-date table of contents is located at the top of the main script.
WEIGHT GAIN FILTERS
A collection of moving average type filters with adjustable volume weighting.
Based upon the two most common methods of volume weighting.
'Simple' uses the standard method in which a basic VWMA is analogous to SMA.
'Elastic' uses exponential method found in EVWMA which is analogous to RMA.
Volume weighting is applied according to an exponent multiplier of input volume.
0 >> volume^0 (unweighted), 1 >> volume^1 (fully weighted), use float values for intermediate weighting.
Additional volume filter switch for smoothing of outlier events.
DIVA MODULAR DEVIATIONS
A small collection of standard and absolute deviations.
Includes the weightgain functionality as above.
Basic modular functionality for more creative uses.
Optional input (ct) for external central tendency (aka: estimator).
Can be assigned to alternative filter or any float value. Will default to internal filter when no ct input is received.
Some other useful or related functions included at the bottom along with basic demonstration use.
weightgain_sma(src, len, xVol, fVol)
Simple Moving Average (SMA): Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Standard Simple Moving Average with Simple Weight Gain applied.
weightgain_hsma(src, len, xVol, fVol)
Harmonic Simple Moving Average (hSMA): Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Harmonic Simple Moving Average with Simple Weight Gain applied.
weightgain_gsma(src, len, xVol, fVol)
Geometric Simple Moving Average (gSMA): Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Geometric Simple Moving Average with Simple Weight Gain applied.
weightgain_wma(src, len, xVol, fVol)
Linear Weighted Moving Average (WMA): Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Basic Linear Weighted Moving Average with Simple Weight Gain applied.
weightgain_hma(src, len, xVol, fVol)
Hull Moving Average (HMA): Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Basic Hull Moving Average with Simple Weight Gain applied.
diva_sd_sma(src, len, xVol, fVol, ct)
Standard Deviation (SD SMA): Diva / Weight Gain (Simple Volume)
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_sma().
Returns:
diva_sd_wma(src, len, xVol, fVol, ct)
Standard Deviation (SD WMA): Diva / Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_wma().
Returns:
diva_aad_sma(src, len, xVol, fVol, ct)
Average Absolute Deviation (AAD SMA): Diva / Weight Gain (Simple Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_sma().
Returns:
diva_aad_wma(src, len, xVol, fVol, ct)
Average Absolute Deviation (AAD WMA): Diva / Weight Gain (Simple Volume) .
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_wma().
Returns:
weightgain_ema(src, len, xVol, fVol)
Exponential Moving Average (EMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Exponential Moving Average with Elastic Weight Gain applied.
weightgain_dema(src, len, xVol, fVol)
Double Exponential Moving Average (DEMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Double Exponential Moving Average with Elastic Weight Gain applied.
weightgain_tema(src, len, xVol, fVol)
Triple Exponential Moving Average (TEMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Triple Exponential Moving Average with Elastic Weight Gain applied.
weightgain_rma(src, len, xVol, fVol)
Rolling Moving Average (RMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Rolling Moving Average with Elastic Weight Gain applied.
weightgain_drma(src, len, xVol, fVol)
Double Rolling Moving Average (DRMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Double Rolling Moving Average with Elastic Weight Gain applied.
weightgain_trma(src, len, xVol, fVol)
Triple Rolling Moving Average (TRMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: Triple Rolling Moving Average with Elastic Weight Gain applied.
diva_sd_ema(src, len, xVol, fVol, ct)
Standard Deviation (SD EMA): Diva / Weight Gain: (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_ema().
Returns:
diva_sd_rma(src, len, xVol, fVol, ct)
Standard Deviation (SD RMA): Diva / Weight Gain: (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_rma().
Returns:
weightgain_vidya_rma(src, len, xVol, fVol)
VIDYA v1 RMA base (VIDYA-RMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: VIDYA v1, RMA base with Elastic Weight Gain applied.
weightgain_vidya_ema(src, len, xVol, fVol)
VIDYA v1 EMA base (VIDYA-EMA): Weight Gain (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
Returns: VIDYA v1, EMA base with Elastic Weight Gain applied.
diva_sd_vidya_rma(src, len, xVol, fVol, ct)
Standard Deviation (SD VIDYA-RMA): Diva / Weight Gain: (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_vidya_rma().
Returns:
diva_sd_vidya_ema(src, len, xVol, fVol, ct)
Standard Deviation (SD VIDYA-EMA): Diva / Weight Gain: (Elastic Volume).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
xVol (float) : Volume exponent multiplier (0 = unweighted, 1 = fully weighted).
fVol (bool) : Volume smoothing filter.
ct (float) : Central tendency (optional, na = bypass). Internal: weightgain_vidya_ema().
Returns:
weightgain_sema(src, len, xVol, fVol)
Parameters:
src (float)
len (simple int)
xVol (float)
fVol (bool)
diva_sd_sema(src, len, xVol, fVol)
Parameters:
src (float)
len (simple int)
xVol (float)
fVol (bool)
diva_mad_mm(src, len, ct)
Median Absolute Deviation (MAD MM): Diva (no volume weighting).
Parameters:
src (float) : Source input.
len (int) : Length (number of bars).
ct (float) : Central tendency (optional, na = bypass). Internal: ta.median()
Returns:
source_switch(slct, aux1, aux2, aux3, aux4)
Custom Source Selector/Switch function. Features standard & custom 'weighted' sources with additional aux inputs.
Parameters:
slct (string) : Choose from custom set of string values.
aux1 (float) : Additional input for user-defined source, eg: standard input.source(). Optional, use na to bypass.
aux2 (float) : Additional input for user-defined source, eg: standard input.source(). Optional, use na to bypass.
aux3 (float) : Additional input for user-defined source, eg: standard input.source(). Optional, use na to bypass.
aux4 (float) : Additional input for user-defined source, eg: standard input.source(). Optional, use na to bypass.
Returns: Float value, to be used as src input for other functions.
colour_gradient_ma_div(ma1, ma2, div, bull, bear, mid, mult)
Colour Gradient for plot fill between two moving averages etc, with seperate bull/bear and divergence strength.
Parameters:
ma1 (float) : Input for fast moving average (eg: bullish when above ma2).
ma2 (float) : Input for slow moving average (eg: bullish when below ma1).
div (float) : Input deviation/divergence value used to calculate strength of colour.
bull (color) : Colour when ma1 above ma2.
bear (color) : Colour when ma1 below ma2.
mid (color) : Neutral colour when ma1 = ma2.
mult (int) : Opacity multiplier. 100 = maximum, 0 = transparent.
Returns: Colour with transparency (according to specified inputs)
Volumeweighted
CMF and Scaled EFI OverlayCMF and Scaled EFI Overlay Indicator
Overview
The CMF and Scaled EFI Overlay indicator combines the Chaikin Money Flow (CMF) and a scaled version of the Elder Force Index (EFI) into a single chart. This allows traders to analyze both indicators simultaneously, facilitating better insights into market momentum and volume dynamics , specifically focusing on buying/selling pressure and momentum , without compromising the integrity of either indicator.
Purpose
Chaikin Money Flow (CMF): Measures buying and selling pressure by evaluating price and volume over a specified period. It indicates accumulation (buying pressure) when values are positive and distribution (selling pressure) when values are negative.
Elder Force Index (EFI): Combines price changes and volume to assess the momentum behind market moves. Positive values indicate upward momentum (prices rising with strong volume), while negative values indicate downward momentum (prices falling with strong volume).
By scaling the EFI to match the amplitude of the CMF, this indicator enables a direct comparison between pressure and momentum , preserving their shapes and zero crossings. Traders can observe the relationship between price movements, volume, and momentum more effectively, aiding in decision-making.
Understanding Pressure vs. Momentum
Chaikin Money Flow (CMF):
- Indicates the level of demand (buying pressure) or supply (selling pressure) in the market based on volume and price movements.
- Accumulation: When institutional or large investors are buying significant amounts of an asset, leading to an increase in buying pressure.
- Distribution: When these investors are selling off their holdings, increasing selling pressure.
Elder Force Index (EFI):
- Measures the strength and speed of price movements, indicating how forceful the current trend is.
- Positive Momentum: Prices are rising quickly, indicating a strong uptrend.
- Negative Momentum: Prices are falling rapidly, indicating a strong downtrend.
Understanding the difference between pressure and momentum is crucial. For example, a market may exhibit strong buying pressure (positive CMF) but weak momentum (low EFI), suggesting accumulation without significant price movement yet.
Features
Overlay of CMF and Scaled EFI: Both indicators are plotted on the same chart for easy comparison of pressure and momentum dynamics.
Customizable Parameters: Adjust lengths for CMF and EFI calculations and fine-tune the scaling factor for optimal alignment.
Preserved Indicator Integrity: The scaling method preserves the shape and zero crossings of the EFI, ensuring accurate analysis.
How It Works
CMF Calculation:
- Calculates the Money Flow Multiplier (MFM) and Money Flow Volume (MFV) to assess buying and selling pressure.
- CMF is computed by summing the MFV over the specified length and dividing by the sum of volume over the same period:
CMF = (Sum of MFV over n periods) / (Sum of Volume over n periods)
EFI Calculation:
- Calculates the EFI using the Exponential Moving Average (EMA) of the price change multiplied by volume:
EFI = EMA(n, Change in Close * Volume)
Scaling the EFI:
- The EFI is scaled by multiplying it with a user-defined scaling factor to match the CMF's amplitude.
Plotting:
- Both the CMF and the scaled EFI are plotted on the same chart.
- A zero line is included for reference, aiding in identifying crossovers and divergences.
Indicator Settings
Inputs
CMF Length (`cmf_length`):
- Default: 20
- Description: The number of periods over which the CMF is calculated. A higher value smooths the indicator but may delay signals.
EFI Length (`efi_length`):
- Default: 13
- Description: The EMA length for the EFI calculation. Adjusting this value affects the sensitivity of the EFI to price changes.
EFI Scaling Factor (`efi_scaling_factor`):
- Default: 0.000001
- Description: A constant used to scale the EFI to match the CMF's amplitude. Fine-tuning this value ensures the indicators align visually.
How to Adjust the EFI Scaling Factor
Start with the Default Value:
- Begin with the default scaling factor of `0.000001`.
Visual Inspection:
- Observe the plotted indicators. If the EFI appears too large or small compared to the CMF, proceed to adjust the scaling factor.
Fine-Tune the Scaling Factor:
- Increase or decrease the scaling factor incrementally (e.g., `0.000005`, `0.00001`, `0.00005`) until the amplitudes of the CMF and EFI visually align.
- The optimal scaling factor may vary depending on the asset and timeframe.
Verify Alignment:
- Ensure that the scaled EFI preserves the shape and zero crossings of the original EFI.
- Overlay the original EFI (if desired) to confirm alignment.
How to Use the Indicator
Analyze Buying/Selling Pressure and Momentum:
- Positive CMF (>0): Indicates accumulation (buying pressure).
- Negative CMF (<0): Indicates distribution (selling pressure).
- Positive EFI: Indicates positive momentum (prices rising with strong volume).
- Negative EFI: Indicates negative momentum (prices falling with strong volume).
Look for Indicator Alignment:
- Both CMF and EFI Positive:
- Suggests strong bullish conditions with both buying pressure and upward momentum.
- Both CMF and EFI Negative:
- Indicates strong bearish conditions with selling pressure and downward momentum.
Identify Divergences:
- CMF Positive, EFI Negative:
- Buying pressure exists, but momentum is negative; potential for a bullish reversal if momentum shifts.
- CMF Negative, EFI Positive:
- Selling pressure exists despite rising prices; caution advised as it may indicate a potential bearish reversal.
Confirm Signals with Other Analysis:
- Use this indicator in conjunction with other technical analysis tools (e.g., trend lines, support/resistance levels) to confirm trading decisions.
Example Usage
Scenario 1: Bullish Alignment
- CMF Positive: Indicates accumulation (buying pressure).
- EFI Positive and Increasing: Shows strengthening upward momentum.
- Interpretation:
- Strong bullish signal suggesting that buyers are active, and the price is likely to continue rising.
- Action:
- Consider entering a long position or adding to existing ones.
Scenario 2: Bearish Divergence
- CMF Negative: Indicates distribution (selling pressure).
- EFI Positive but Decreasing: Momentum is positive but weakening.
- Interpretation:
- Potential bearish reversal; price may be rising but underlying selling pressure suggests caution.
- Action:
- Be cautious with long positions; consider tightening stop-losses or preparing for a possible trend reversal.
Tips
Adjust for Different Assets:
- The optimal scaling factor may differ across assets due to varying price and volume characteristics.
- Always adjust the scaling factor when analyzing a new asset.
Monitor Indicator Crossovers:
- Crossings above or below the zero line can signal potential trend changes.
Watch for Divergences:
- Divergences between the CMF and EFI can provide early warning signs of trend reversals.
Combine with Other Indicators:
- Enhance your analysis by combining this overlay with other indicators like moving averages, RSI, or Ichimoku Cloud.
Limitations
Scaling Factor Sensitivity:
- An incorrect scaling factor may misalign the indicators, leading to inaccurate interpretations.
- Regular adjustments may be necessary when switching between different assets or timeframes.
Not a Standalone Indicator:
- Should be used as part of a comprehensive trading strategy.
- Always consider other market factors and indicators before making trading decisions.
Disclaimer
No Guarantee of Performance:
- Past performance is not indicative of future results.
- Trading involves risk, and losses can exceed deposits.
Use at Your Own Risk:
- This indicator is provided for educational purposes.
- The author is not responsible for any financial losses incurred while using this indicator.
Code Summary
//@version=5
indicator(title="CMF and Scaled EFI Overlay", shorttitle="CMF & Scaled EFI", overlay=false)
cmf_length = input.int(20, minval=1, title="CMF Length")
efi_length = input.int(13, minval=1, title="EFI Length")
efi_scaling_factor = input.float(0.000001, title="EFI Scaling Factor", minval=0.0, step=0.000001)
// --- CMF Calculation ---
ad = high != low ? ((2 * close - low - high) / (high - low)) * volume : 0
mf = math.sum(ad, cmf_length) / math.sum(volume, cmf_length)
// --- EFI Calculation ---
efi_raw = ta.ema(ta.change(close) * volume, efi_length)
// --- Scale EFI ---
efi_scaled = efi_raw * efi_scaling_factor
// --- Plotting ---
plot(mf, color=color.green, title="CMF", linewidth=2)
plot(efi_scaled, color=color.red, title="EFI (Scaled)", linewidth=2)
hline(0, color=color.gray, title="Zero Line", linestyle=hline.style_dashed)
- Lines 4-6: Define input parameters for CMF length, EFI length, and EFI scaling factor.
- Lines 9-11: Calculate the CMF.
- Lines 14-16: Calculate the EFI.
- Line 19: Scale the EFI by the scaling factor.
- Lines 22-24: Plot the CMF, scaled EFI, and zero line.
Feedback and Support
Suggestions: If you have ideas for improvements or additional features, please share your feedback.
Support: For assistance or questions regarding this indicator, feel free to contact the author through TradingView.
---
By combining the CMF and scaled EFI into a single overlay, this indicator provides a powerful tool for traders to analyze market dynamics more comprehensively. Adjust the parameters to suit your trading style, and always practice sound risk management.
Big Volumes HighlighterBig Volumes Highlighter
Overview:
The "Big Volume Highlighter" is a powerful tool designed to help traders quickly identify candles with the highest trading volume over a specified period. This indicator not only highlights the most significant volume candles but also color-codes them based on the candle's direction—green for bullish (close > open) and red for bearish (close < open). Whether you're analyzing volume spikes or looking for key moments in price action, this indicator provides clear visual cues to enhance your trading decisions.
Features:
Customizable Lookback Period: Define the number of candles to consider when determining the highest volume.
Automatic Color Coding: Candles with the highest volume are highlighted in green if bullish and red if bearish.
Visual Clarity: The indicator marks the significant volume candles with a triangle above the bar and changes the background color to match, making it easy to spot important volume events at a glance.
Use Cases:
Volume Spike Detection:
Quickly identify when a large volume enters the market, which may indicate significant buying or selling pressure.
Trend Confirmation: Use volume spikes to confirm trends or potential reversals by observing the direction of the high-volume candles.
Market Sentiment Analysis: Understand market sentiment by analyzing the direction of the candles with the biggest volumes.
How to Use:
Add the "Big Volume Highlighter" to your chart.
Adjust the lookback period to suit your analysis.
Observe the highlighted candles for insights into market dynamics.
This script is ideal for traders who want to incorporate volume analysis into their technical strategy, providing a simple yet effective way to monitor significant volume changes in the market.
Consolidation VWAP's [QuantVue]Introducing the Consolidation VWAP's Indicator , a powerful tool designed to identify consolidation periods in stock advance and automatically anchor three distinct VWAPs to key points within the consolidation.
Consolidation Period Identification:
The indicator automatically detects periods of consolidation or areas on the chart where a stock's price moves sideways within a defined range. This period can be seen as the market taking a "breather" as it digests the previous gains. Consolidations are important because they often act as a base for the next move, either continuing the previous uptrend or reversing direction.
Consolidation requirements can be customized by the user to match your instrument and timeframe.
Maximum Consolidation Depth
Minimum Consolidation Length
Maximum Consolidation Length
Prior Uptrend Amount
Anchored VWAP, or Anchored Volume-Weighted Average Price, is a technical analysis tool used to determine the average price of a stock weighted by volume, starting from a specific point in time chosen by the analyst.
Unlike traditional VWAP, which starts at the beginning of the trading session, the anchored VWAP allows traders to select any point on the chart, such as a significant event, price low, high, or a breakout, to begin the calculation.
VWAP incorporates price and volume in a weighted average and can be used to identify areas of support and resistance on the chart.
VWAP Anchored to Consolidation High: This VWAP is anchored at the highest price point within the identified consolidation period. It helps traders understand the
average price paid by buyers who entered at the peak of the consolidation.
VWAP Anchored to Consolidation Low: This VWAP is anchored at the lowest price point within the consolidation. It provides insights into the average price paid by
buyers who entered at the lowest point of the consolidation.
VWAP Anchored to Highest Volume in the Consolidation: This VWAP is anchored at the price level with the highest trading volume during the consolidation. It reflects the average price at
which the most trading activity occurred, often indicating a key support or resistance level.
The indicator also allows the trader to see past consolidation areas and previous anchored VWAP's.
Give this indicator a BOOST and COMMENT your thoughts!
We hope you enjoy.
Cheers!
VWAP LEVELS [PRO]32 VWAP levels with labels and a table to help you identify quickly where current price is in relation to your favorite VWAP pivot levels. To help reduce cognitive load, 4 colors are used to show you where price is in relation to a VWAP level as well as the strength of that respective level. Ultimately, VWAP can be an invaluable source of support and resistance; in other words you'll often see price bounce off of a level (whether price is increasing or decreasing) once or multiple times and that could be an indication of a price's direction. Another way that you could utilize this indicator is to use it in confluence with other popular signals, such as an EMA crossover. Many traders will wait till a bar's close on the 5m or 10m time frame above a VWAP level (developing 1D VWAP would be a popular choice) before making a decision on a potential trade especially if price is rising above the 1D VWAP *and* there's been a recent 100 EMA cross UP of the 200 EMA. These are 2 bullish signals that you could look for before possibly entering in to a trade.
I've made this indicator extremely customizable:
⚡Each VWAP level has 2 labels: 1 "at level" and 1 "at right", each label and price can be disabled
⚡Each VWAP label has its own input for label padding. The "at right" label padding input allows you to zoom in and out of a chart without the labels moving along their respective axis. However, the "at level" label padding input doesn't work the same way once you move the label out of the "0" input. The label will move slightly when you zoom in and out
⚡Both "current" and "previous" VWAP levels have their own plot style that can be changed from circles, crosses and lines
⚡Significant figures input allows you to round a price up or down
⚡A price line that allows you to identify where price is in relation to a VWAP level
⚡A table that's color coded the same way as the labels. The labels and table cells change to 1 of 4 colors when "OC Check Mode" is enabled. This theory examines if the VWAP from the Open is above or below the VWAP from Close and if price is above or below normal VWAP (HLC3). This way we have 4 states:
Red = Strong Downtrend
Light Red = Weak Downtrend
Light = Weak Uptrend
Green = Strong Uptrend
Something to keep in mind: At the start of a new year, week or month, some levels will converge and they'll eventually diverge slowly or quickly depending on the level and/or time frame. You could add a few labels "at level" to show which levels are converging at the time. Since we're at the beginning of a new year, you'll see current month, 2 month, 3 month etc converge in to one level.
🙏Thanks to (c)MartinWeb for the inspiration behind this indicator.
🙏Thanks to (c)SimpleCryptoLife for the libraries and code to help create the labels.
Machine Learning: STDEV Oscillator [YinYangAlgorithms]This Indicator aims to fill a gap within traditional Standard Deviation Analysis. Rather than its usual applications, this Indicator focuses on applying Standard Deviation within an Oscillator and likewise applying a Machine Learning approach to it. By doing so, we may hope to achieve an Adaptive Oscillator which can help display when the price is deviating from its standard movement. This Indicator may help display both when the price is Overbought or Underbought, and likewise, where the price may face Support and Resistance. The reason for this is that rather than simply plotting a Machine Learning Standard Deviation (STDEV), we instead create a High and a Low variant of STDEV, and then use its Highest and Lowest values calculated within another Deviation to create Deviation Zones. These zones may help to display these Support and Resistance locations; and likewise may help to show if the price is Overbought or Oversold based on its placement within these zones. This Oscillator may also help display Momentum when the High and/or Low STDEV crosses the midline (0). Lastly, this Oscillator may also be useful for seeing the spacing between the High and Low of the STDEV; large spacing may represent volatility within the STDEV which may be helpful for seeing when there is Momentum in the form of volatility.
Tutorial:
Above is an example of how this Indicator looks on BTC/USDT 1 Day. As you may see, when the price has parabolic movement, so does the STDEV. This is due to this price movement deviating from the mean of the data. Therefore when these parabolic movements occur, we create the Deviation Zones accordingly, in hopes that it may help to project future Support and Resistance locations as well as helping to display when the price is Overbought and Oversold.
If we zoom in a little bit, you may notice that the Support Zone (Blue) is smaller than the Resistance Zone (Orange). This is simply because during the last Bull Market there was more parabolic price deviation than there was during the Bear Market. You may see this if you refer to their values; the Resistance Zone goes to ~18k whereas the Support Zone is ~10.5k. This is completely normal and the way it is supposed to work. Due to the nature of how STDEV works, this Oscillator doesn’t use a 1:1 ratio and instead can develop and expand as exponential price action occurs.
The Neutral (0) line may also act as a Support and Resistance location. In the example above we can see how when the STDEV is below it, it acts as Resistance; and when it’s above it, it acts as Support.
This Neutral line may also provide us with insight as towards the momentum within the market and when it has shifted. When the STDEV is below the Neutral line, the market may be considered Bearish. When the STDEV is above the Neutral line, the market may be considered Bullish.
The Red Line represents the STDEV’s High and the Green Line represents the STDEV’s Low. When the STDEV’s High and Low get tight and close together, this may represent there is currently Low Volatility in the market. Low Volatility may cause consolidation to occur, however it also leaves room for expansion.
However, when the STDEV’s High and Low are quite spaced apart, this may represent High levels of Volatility in the market. This may mean the market is more prone to parabolic movements and expansion.
We will conclude our Tutorial here. Hopefully this has given you some insight into how applying Machine Learning to a High and Low STDEV then creating Deviation Zones based on it may help project when the Momentum of the Market is Bullish or Bearish; likewise when the price is Overbought or Oversold; and lastly where the price may face Support and Resistance in the form of STDEV.
If you have any questions, comments, ideas or concerns please don't hesitate to contact us.
HAPPY TRADING!
Machine Learning: VWAP [YinYangAlgorithms]Machine Learning: VWAP aims to use Machine Learning to Identify the best location to Anchor the VWAP at. Rather than using a traditional fixed length or simply adjusting based on a Date / Time; by applying Machine Learning we may hope to identify crucial areas which make sense to reset the VWAP and start anew. VWAP’s may act similar to a Bollinger Band in the sense that they help to identify both Overbought and Oversold Price locations based on previous movements and help to identify how far the price may move within the current Trend. However, unlike Bollinger Bands, VWAPs have the ability to parabolically get quite spaced out and also reset. For this reason, the price may never actually go from the Lower to the Upper and vice versa (when very spaced out; when the Upper and Lower zones are narrow, it may bounce between the two). The reason for this is due to how the anchor location is calculated and in this specific Indicator, how it changes anchors based on price movement calculated within Machine Learning.
This Indicator changes the anchor if the Low < Lowest Low of a length of X and likewise if the High > Highest High of a length of X. This logic is applied within a Machine Learning standpoint that likewise amplifies this Lookback Length by adding a Machine Learning Length to it and increasing the lookback length even further.
Due to how the anchor for this VWAP changes, you may notice that the Basis Line (Orange) may act as a Trend Identifier. When the Price is above the basis line, it may represent a bullish trend; and likewise it may represent a bearish trend when below it. You may also notice what may happen is when the trend occurs, it may push all the way to the Upper or Lower levels of this VWAP. It may then proceed to move horizontally until the VWAP expands more and it may gain more movement; or it may correct back to the Basis Line. If it corrects back to the basis line, what may happen is it either uses the Basis Line as a Support and continues in its current direction, or it will change the VWAP anchor and start anew.
Tutorial:
If we zoom in on the most recent VWAP we can see how it expands. Expansion may be caused by time but generally it may be caused by price movement and volume. Exponential Price movement causes the VWAP to expand, even if there are corrections to it. However, please note Volume adds a large weighted factor to the calculation; hence Volume Weighted Average Price (VWAP).
If you refer to the white circle in the example above; you’ll be able to see that the VWAP expanded even while the price was correcting to the Basis line. This happens due to exponential movement which holds high volume. If you look at the volume below the white circle, you’ll notice it was very large; however even though there was exponential price movement after the white circle, since the volume was low, the VWAP didn’t expand much more than it already had.
There may be times where both Volume and Price movement isn’t significant enough to cause much of an expansion. During this time it may be considered to be in a state of consolidation. While looking at this example, you may also notice the color switch from red to green to red. The color of the VWAP is related to the movement of the Basis line (Orange middle line). When the current basis is > the basis of the previous bar the color of the VWAP is green, and when the current basis is < the basis of the previous bar, the color of the VWAP is red. The color may help you gauge the current directional movement the price is facing within the VWAP.
You may have noticed there are signals within this Indicator. These signals are composed of Green and Red Triangles which represent potential Bullish and Bearish momentum changes. The Momentum changes happen when the Signal Type:
The High/Low or Close (You pick in settings)
Crosses one of the locations within the VWAP.
Bullish Momentum change signals occur when :
Signal Type crosses OVER the Basis
Signal Type crosses OVER the lower level
Bearish Momentum change signals occur when:
Signal Type crosses UNDER the Basis
Signal Type Crosses UNDER the upper level
These signals may represent locations where momentum may occur in the direction of these signals. For these reasons there are also alerts available to be set up for them.
If you refer to the two circles within the example above, you may see that when the close goes above the basis line, how it mat represents bullish momentum. Likewise if it corrects back to the basis and the basis acts as a support, it may continue its bullish momentum back to the upper levels again. However, if you refer to the red circle, you’ll see if the basis fails to act as a support, it may then start to correct all the way to the lower levels, or depending on how expanded the VWAP is, it may just reset its anchor due to such drastic movement.
You also have the ability to disable Machine Learning by setting ‘Machine Learning Type’ to ‘None’. If this is done, it will go off whether you have it set to:
Bullish
Bearish
Neutral
For the type of VWAP you want to see. In this example above we have it set to ‘Bullish’. Non Machine Learning VWAP are still calculated using the same logic of if low < lowest low over length of X and if high > highest high over length of X.
Non Machine Learning VWAP’s change much quicker but may also allow the price to correct from one side to the other without changing VWAP Anchor. They may be useful for breaking up a trend into smaller pieces after momentum may have changed.
Above is an example of how the Non Machine Learning VWAP looks like when in Bearish. As you can see based on if it is Bullish or Bearish is how it favors the trend to be and may likewise dictate when it changes the Anchor.
When set to neutral however, the Anchor may change quite quickly. This results in a still useful VWAP to help dictate possible zones that the price may move within, but they’re also much tighter zones that may not expand the same way.
We will conclude this Tutorial here, hopefully this gives you some insight as to why and how Machine Learning VWAPs may be useful; as well as how to use them.
Settings:
VWAP:
VWAP Type: Type of VWAP. You can favor specific direction changes or let it be Neutral where there is even weight to both. Please note, these do not apply to the Machine Learning VWAP.
Source: VWAP Source. By default VWAP usually uses HLC3; however OHLC4 may help by providing more data.
Lookback Length: The Length of this VWAP when it comes to seeing if the current High > Highest of this length; or if the current Low is < Lowest of this length.
Standard VWAP Multiplier: This multiplier is applied only to the Standard VWMA. This is when 'Machine Learning Type' is set to 'None'.
Machine Learning:
Use Rational Quadratics: Rationalizing our source may be beneficial for usage within ML calculations.
Signal Type: Bullish and Bearish Signals are when the price crosses over/under the basis, as well as the Upper and Lower levels. These may act as indicators to where price movement may occur.
Machine Learning Type: Are we using a Simple ML Average, KNN Mean Average, KNN Exponential Average or None?
KNN Distance Type: We need to check if distance is within the KNN Min/Max distance, which distance checks are we using.
Machine Learning Length: How far back is our Machine Learning going to keep data for.
k-Nearest Neighbour (KNN) Length: How many k-Nearest Neighbours will we account for?
Fast ML Data Length: What is our Fast ML Length? This is used with our Slow Length to create our KNN Distance.
Slow ML Data Length: What is our Slow ML Length? This is used with our Fast Length to create our KNN Distance.
If you have any questions, comments, ideas or concerns please don't hesitate to contact us.
HAPPY TRADING!
Volume-Weighted RSI [wbburgin]The Volume-Weighted RSI takes a new approach to the traditional calculation of the RSI in using a price::volume calculation. As some traders consider volume to be a leading indicator for price, the volume-weighted RSI can come in handy if you want to visualize volume easier.
Usage
This indicator builds the RSI from the square of the volume change and the price. If the volume decreases rapidly with the price, the volume-weighted RSI will fall; if the volume increases rapidly with the price, the volume-weighted RSI will rise.
You may notice crosses and circles appearing above and below the indicator. These indicate abnormal volume or price:
A green cross indicates abnormal upward price
A red cross indicates abnormal downward price
A green circle indicates abnormal positive volume
A red circle indicates abnormal negative volume
A green bar indicates both abnormal price and volume (positive), while a red bar indicates both abnormal price and volume (negative).
The thresholds of what are considered "normal" and "abnormal" are controlled by the "SD Multiple" in your settings (standard deviation). A higher multiple will make less of these signals occur, and you can turn them and the bars off at any time.
I have a built-in Light Style and Dark Style so that your preference of background won't affect seeing the indicator. You can also change the colors and the overbought/oversold lines in your settings.
Diddly - Real Volume TrendDiddly Real Volume Trend is an indicator to help traders identify the real trending direction of an asset, it achieves this by using liquidity to assess the overall buying and selling volume sentiment of a market place.
What is Liquidity
Liquidity refers to the ability of an asset to be turned into cash. Cash is the more liquid form of any asset, whereas selling a house would take a little longer to liquidate and convert to cash. Liquidity in financial markets is in essence based on the same principle and refers to how easily an asset can be bought and sold.
Liquidity in simple terms is the volume of participants who are willing to be involved in the market at any given time. Markets are based on auction theory, the more participants who want to buy at a certain price than sell, will dictate that the price goes up. As a result it is important to understand the role that volume has in financial markets, as volume will directly correlate to liquidity and supply and demand.
What does it mean?
Although markets are based on auction theory, sadly we don't have the advantage of a traditional auction, where we are all sitting in a room putting our hands in the air when we are interested in paying x price for a particular item. In this environment it is very clear to see how popular the item for sale is and whether it is possible to pick up a bargain.
Being able to identify the prevailing direction of buying versus selling volume on a chart provides an insight into market sentiment. Also we have to consider that typically most retail traders participate in very liquid markets, where you can get in and out of a position with relative ease.
There are obviously exceptions, extremely low float stocks, but on the whole with liquid assets it takes some big orders to move price, especially with currencies and high float stocks. Understanding these principles helps us as retail traders identify where the big money is seeing a bargain, if buying or overpriced if selling.
However you identify liquidity, I hope you agree that it is an extremely important element to be considering before taking a trade. The last thing any trader wants to be doing if they can avoid it, is getting on the wrong side of the market.
Just as a side note, high and low "Float Stocks" refers to the number of shares in general circulation for buying and selling.
What is "Diddly Real Volume Trend"
This volume trend indicator in simple terms will display the combined accumulated bullish and bearish volume within a window below the main chart. What you will see is a line chart that will be doing one of three things. Either it could be stair stepping in an upwards direction, identifying that we are in a bullish trend or stepping down in a bearish trend. Alternatively it could just be going sideways, which would suggest a ranging market.
This enables traders to make an assessment of the market sentiment using the liquidity direction that it has identified. This can help form an overall daily bias for intra-day traders or help confirm a longer term trend for swing traders.
Although this indicator is not a true oscillator (where the limits of number are fixed between a known upper and lower limit) , it can still be extremely useful in identifying divergence in price and the volume sentiment. As well as assisting in the process of identifying and confirming peak formations and potential reversal points in a market.
How does it Work
The indicator is plotting the volume trend line based on the output of a set of volume calculations, which is confirmed on the close of each candle. The resultant output is either a positive (Bullish sentiment) or negative (Bearish Sentiment), which are all totalled up to show the next point on the graph. As a result the visual effect seen from this process is that the more bullish calculated volume identified than bearish, you will see a rising trend line and the reverse for a bearish market.
The algo calculation which is used on each candle and its related volume is using the following elements.
Volume
Rate of Change
Relative Strength
The indicator is not just looking at the volume total and saying this is a green candle and must provide a positive number. It is looking for the volume and liquidity extremes and filtering out the nothingness of a market that makes no difference to price either way. It is from using these extremes that the indicator is able to plot the activities and direction of the big money in the market.
What is the Indicator Showing me?
Examples:
Here on a stock VKTX, on a 1 minute chart the elements that make up the indicator are annotated on the chart.
There are 6 components highlighted in the above chart, these have been listed below.
Volume Trend Line
This is the indicator driving line and is the result of the calculations described in the previous section.
Fast Moving Average
This is the fast moving average of the "Volume Trend Line". The moving average type and length can be changed in the settings.
(Default = Exponential Moving Average, Length: 60)
Slow Moving Average
This is a slower moving average of the "Volume Trend Line". The moving average type and length can be changed in the settings.
(Default = Hull Moving Average, Length: 3500)
Long Term Moving Average
This is a long term moving average of the "Volume Trend Line". The moving average type and length can be changed in the settings.
(Default = Exponential Moving Average, Length: 400)
Bullish Confirmation
On the "Volume Trend Line", you will see coloured circles dotted along the line, the green circles signifying Bullish Confirmation.
Bearish Confirmation
On the "Volume Trend Line", you will see coloured circles dotted along the line, the red circles signifying Bearish Confirmation.
The Bullish and Bearish confirmation signals are not signals to take trades, they are there to highlight the predominant direction. Seeing one confirmation signal in isolation is not that helpful, but continued prints of confirmation in a single direction would be interesting.
There are a further two signal types that are displayed on the volume trend line, these should be seen infrequently across charts and represent potential extremes of price movement in a single direction. These signals act as a warning that price could stall in this area or potentially make a reversal. As with the other signals within this indicator they are not signals to buy or sell, they are there to provide warning alerts and should be considered with other pieces of information that you are working with.
Bullish Extreme
Plotted on the "Volume Trend Line", you will occasionally see a green coloured downwardly pointing triangle, this represents a Bullish Extreme.
GBPAUD Hourly chart October 2022
Bearish Extreme
Plotted on the "Volume Trend Line", you will occasionally see a red coloured upward pointing triangle, this represents a Bearish Extreme.
GBPAUD Daily chart (February - April) 2023
How Does It Help?
This indicator will compliment any existing strategy and is not intended to be used standalone.
It can be used on any chart from a monthly, one minute to one second, depending on your trading strategy. Using multiple time frame analysis can help traders with a number of decisions that need to be considered before taking entries.
What is my market direction bias?
This can be taken from an hourly for intraday trader or daily for swing traders. What that time frame is depends on your trading plan and objectives from the trades you take.
When do I take my trades?
Again depending on the trading strategy used will dictate many aspect of this decision, although using the volume trend on a lower time frame, can help confirm breakouts, reversals and divergence.
How should I manage my trade?
With any trade you should have a defined risk reward clearly defined, with stops and targets in mind before taking an entry.
The age old saying of "cut your losses quickly and let your winner run", is easier said than mastered. Once in a trade the volume trend can be really helpful to identify trades that could be real runners and allows you to change expectations after entering the trade. Maybe you want to take some profit at the original point and let the remaining run. Maybe there is such strength you want to add to the position. Being able to assess market sentiment once in a trade can help with optimising returns.
The "Volume Trend Line", which is the driving element of this indicator, will be doing one of three things. Either it could be stair stepping in an upwards direction, identifying that we are in a bullish trend, stepping down in a bearish trend or going sideways in a ranging market.
Bullish Volume Trending Market
Here is stock VKTX, on a 1 minute chart. Trend confirmation on price action is determined by Higher Highs and Higher Lows for an uptrend or Lower Lows and Lower Highs on a downtrend. The same principle applies for the volume trend line.
In this example we first see breakout volume on the indicator with the Bullish Break volume, following that the volume trend keeps making higher highs and higher lows, confirming that this asset has short-term upwards potential. (why short-term? this is the 1 minute chart, you would want to consult the daily or hourly for a longer term perspective).
Price also is making higher highs and higher lows, which is in alignment with the indicator and known as "convergence" and is a positive signal for a continued trend.
Bearish Market
So here on Tesla (TSLA) on the 4 hour chart we can see the big sell off that started in April 2022. Where it clearly shows a downward trend, with lots of confirmation for continuation.
Ranging Markets
On this example on the AUDJPY 1 Hour chart, we can see that price is in a ranging market. By drawing trend lines on price and the indicator, it is clear to see that price and the volume trend line are both showing a ranging market. What is more interesting is the structure of the ranges.
The price range at the top of the chart is in an upward direction, whereas the volume trend in the bottom window is showing a downward range. Giving us an early indication of what to expect from this asset.
Diverging Markets
"Divergence" is a very powerful mechanism for identifying potential reversal points in price actions. There is a wealth of published information on this topic which is well worth reviewing, if this is a new principle to you.
Here again on the same AUDJPY 1 Hour chart example, points of interest have been annotated on the chart where the historical range turns into a step down to the next level within the market cycle, as predicted by the divergence in range patterns, price point up and volume pointing down.
In the above example, after identifying the divergence the next most important element is an extremely fast accelerated move down which breaks the lower level of the range, this can be seen on the right side of the bottom window and is labelled "Bearish Breaking Volume".
What is interesting here is that the volume indicator has identified the range breakout when price was still above the lower level of the range. Following that break out volume signal, if we zoom out to a 4 hour chart to see what happened next.
The range breakout was confirmed and price and the volume trend continues to show a downward direction in the market. As for entries and stops that is not the intention of this indicator and will be down to other elements in your trading strategy or in our case other indicators.
Peak Formations
Peak formation refers to the point where an asset is over extended in one direction and there is a potential of change in direction, with a wider pullback or a reversal in the higher time frame trend. These formations are often seen with double bottoms (W patterns) or double tops (M patterns) . Unfortunately these patterns appear all over the chart and trading them in isolation will be challenging.
In this example of EURJPY on the 1 hour chart, we see price and the indicator in the bottom window for the first 3 weeks in March 2022. The pair is trending down which is confirmed by both price and the indicator. There are no signals points plotted on the volume trend line, until one appears on March 4th 2022.
Another one appeared on the next trading day of Monday the 7th and we now have these two signals relatively close to each other. This is interesting information, especially considering that there was no extreme signals for the previous couple of months.
Later that day the volume trend broke the previous volume level, after a W pattern was completed and a green bullish confirmation signal was printed. The following day another bullish confirmation signal is displayed to further confirm that we had made a peak formation reversal.
Please note that using the settings style tab, has enabled the change to the bearish extremes signal, changing the colour and shape to be an orange circle. Which for the purposes of this illustration is easier to see.
Another example of the same pair in August 2022, with a very similar confirmation sequence.
Stock Examples
Here on UBER on a 1 hour chart , is an example of how the indicator can be used in confluence with other trading strategies. If a trader was trading candle patterns, they may see this classic 1 hour bull flag pattern forming.
Without the volume trend analysis this looks like a good buy setup. Adding this analysis to the chart we clearly have a different view point.
Here is what subsequently happened to price and this is in a generally bullish market March 2023.
Scalping Entries
For those traders who work with super fast time frames like the 5 second or even on a 1 second charts, the volume indicator can be used to help time entries as a part of a wider trading strategy of trading a pullback or trading support and resistance levels.
Styling options in the indicator settings enabled this different view of the indicator output, which can be extremely useful for timing entries.
Here on this hot IPO stock, LUNR from February 16th 2023, we have an extremely strong move up from $13.80 to $18.00. One aspect of this move up, is that it is doing this on extremely light volume and the predominant market sentiment on the surface seems very bearish.
This would be a clear indication not to trade this stock at this moment in time, as a trader there would be lots of emotions of FOMO (fear of missing out) , seeing a stock making that kind off move on a new IPO - there is the sense that this stock will go to the moon and your not going to be involved.
As traders we have to consider the risk : reward potential. This stock could drop to $10.00 if someone put in a 50 k market sell order, as it is clear there are not the buyers to support that kind of liquidation.
The following charts are in the 5 second time frame, until otherwise stated
So we need to wait for some confirmation of buying liquidity before we can make any plans for taking an entry, which we get in the form of a couple of strong bullish candles on the chart below. Interestingly the price breaks the previous all time high for this stock, although the volume trend at this stage does not seem strong enough to consider an entry.
At this point we should be on the lookout for further buying liquidity, ideally to break the previous high volume line, which appears in the next chart. This would be the time to take an entry based on other aspects of a trading plan.
Having now taken an entry, we can use the indicator to understand the strength of the buying liquidity and identify areas where we should be looking to take profit or close out the trade. Looking at the volume trend profile shown in the chart below, there is no reason not to hold this stock for a wider move up.
In the next chart we see the first signs of some selling pressure, as the indicator shows signs of red. This would be the area to take some profit and look at a higher time frame perspective, to get the sense of whether to hold the remaining position.
Here on the 5 minute time frame the volume trend is still looking very strong to hold the remaining position. As it turned out it was a good place to take profit as it was just under the high of the day.
Knowing when an asset is going to reverse is not easy and this stock was way too over extended and a top had to finally come. This one minute view of the indicator, shows the point where you would see that the upward liquidity was over and you were now on the backside of the move, with no reason to trade further.
Here on a 15 minute chart you can see the full extent of the move and its reversal back to the original price. It provides a clear illustration that chasing trades through FOMO or holding and hoping is not a profitable approach. Being able to time your entries and exits, where you can clearly manage risk is one of the most important elements to any traders strategy.
This is an extreme example and not something you see every day in any market. It has been included within this narrative with the hope that it clearly illustrates the risk involved in trading and being able to mitigate them, has to be at the forefront of your mind.
Key Settings
Within the indicator settings there are a number of options that are available to users. All aspects of what you can see can either be changed or turned on or off in the "Style" tab as well as changing the colours and their transparency.
The available settings on the "Inputs" tab are for fine tuning the indicator to your style of trading. This fine tuning can be applied to the moving averages that can be displayed and follow the volume trend line as well as the volume filtering process.
The most important ones that are in need of explanation are outline below:
General Settings
"What type of asset is the Algo looking at" : Available Options = "Small Caps", "Large Caps", "Futures", "Currencies" (Default Setting = Currencies)
The indicator will make an assessment of the best settings to use as defaults for the volume filtering, confirmation and extremes signals. The defaults can be changed in the following sections using the override.
"Turn on Turbo Mode" : True or False (Default Settings = True)
This setting will give the indicator volume filtering processes a boost
Signal Settings
Based on the "Asset Type" from the general settings, the indicator will make an assessment of the best settings to use by default. These can be changed by using the settings below.
"Override Default Assessment Thresholds" = True / False
"Percentage Difference to Signify Trend Confirmation" = A percentage value that will tell the indicator how to identify the volume trend line swing points used to identify bullish or bearish confirmation signals. Values from 0.1 to 10 would make the most sense. A too high setting and you will not see any confirmation points plotted. Too low and you may see too many to be useful.
"Percentage Difference to Signify Extremes" = A percentage value that will tell the indicator how to identify the volume trend line swing points used to identify bullish or bearish confirmation signals. Values from 20 to 200 would make the most sense. A low a setting and you will see too many extreme points plotted.
Filter Settings
"Turn On Volume Assessment Filters" = True / False : The volume assessment filters are used to focus the "volume trend line" on higher volume extremes.
Based on the "Asset Type" from the general settings, the indicator will make an assessment of the best settings to use by default. These can be changed by using the settings below.
"Override Default Assessment Filters" = True / False
"Filter Volume using Setting" = The number used in this setting represents a value from 0 to 100. Zero will filter out no volume, whereas 100 would filter it all out. The default setting is 1, as there is a danger of setting this number too high and all you will see in the line chart is big steps up and down, with a plateaus in the middle. Which may be useful, although it would not be so helpful in divergence or volume line breaks.
Fast Moving Average
This is the fast moving average of the "Volume Trend Line".
"Moving Average Type" = The type of moving average calculation to be applied.
Default = "EMA"
Available Options: "SMA","EMA" ,"HMA" ,"SMMA (RMA)" ,"WMA" ,"VWMA"
Moving Average Key
SMA : Simple Moving Average
EMA : Exponential Moving Average
HMA : Hull Moving Average
SMMA (RMA) : Exponentially Weighted Moving Average (alpha = 1 / length.)
WMA : Weighted Moving Average
VWMA : Volume Weighted Moving Average
"Moving Average Length" = The number of candles back into the chart used to calculate the Moving Average. (The higher the number, the slower the moving average becomes)
Default Length = 60
"Apply Double Smoothing" = True or False : This is an option to turn on if an extra smoothing effect to the moving average if required.
Slow Moving Average
This is the slow moving average of the "Volume Trend Line".
"Moving Average Type" = The type of moving average calculation to be applied.
Default = "HMA"
Available Options: "SMA","EMA" ,"HMA" ,"SMMA (RMA)" ,"WMA" ,"VWMA"
(See moving average key)
"Moving Average Length" = The number of candles back into the chart used to calculate the Moving Average. (The higher the number, the slower the moving average becomes)
Default Length = 3500
(By default we have a higher number for the slow length compared to the long term length in the next setting. This is because using the Hull Moving Average, is an accelerated moving average that needs higher values to slow it down. If you were to change this to say an EMA, then you would need to change the length to something like 200, to put this slower moving average in context with the others).
Long Term Moving Average
This is a long term moving average of the "Volume Trend Line".
"Moving Average Type" = The type of moving average calculation to be applied.
Default = "EMA"
Available Options: "SMA","EMA" ,"HMA" ,"SMMA (RMA)" ,"WMA" ,"VWMA"
(See moving average key)
"Moving Average Length" = The number of candles back into the chart used to calculate the Moving Average. (The higher the number, the slower the moving average becomes)
Default Length = 400
"Apply Double Smoothing" = True or False : This is an option to turn on if an extra smoothing effect to the moving average if required.
Finally
We greatly appreciate the support and feedback from the Trading View community, and we are dedicated to continuing to improve our indicators with your support.
We want to help you manage risk, and that's why we emphasise that trading is risky and any technology used to support our trading decisions is based on information from the past. We encourage traders to take responsibility for their trading businesses and always prioritise risk management.
Moving Average Based Zig ZagMoving Average Based Zig Zag differs from the traditional Zig Zag indicator in that pivot points are determined by a moving average, Volume Weighted Hull Moving Average, rather than looking for the highest or lowest point in a left / right period.
Settings
Source: the source for the pivot points.
Moving Average Length: the length of the Volume Weighted Hull Moving Average, increase for longer zig zags, decrease for shorter zig zags.
Usage
Like all Zig Zag indicators, the Moving Average Based Zig Zag is not intended to be used as a live trading tool. This indicator is intended to be an alternative way of determining pivot points on your chart. Pivot points can be used for a multitude of different analytical techniques. One may use pivot points in order to draw potential support and resistance lines, trend lines or chart patterns. Additionally, pivot points can be used to determine variations of highs and lows important to market structure analysis such as break of structure or change of character.
Details
The moving average used is a Volume Weighted Hull Moving Average, this particular moving average was used due to it's relatively low-lag characteristics when compared to an Exponential Moving Average, additionally by considering volume in the moving average calculation, insignificant pivot points can be further filtered.
Rather than using built-in functions `ta.pivothigh()` and `ta.pivotlow()` to determine pivot points, this indicator waits for the moving average to pivot then searches for the highest or lowest value from the bar index of the moving average pivot to the bar index of the previous found price pivot. This method of determining pivots provides a more dynamic approach to determining pivot points.
Volume Weighted Reversal BandsThis is a vwap & vwma hybrid with upper & lower deviation bands that provide excellent price channels and reversal areas. It can be used on lower & higher timeframes, just increase the deviation % for higher timeframes. Try out the 1 minute timeframe with .5% deviation for great scalping levels.
Here is the calculation used for the main line.
(VWMA100 + VWMA500 + VWMA1000 + VWAP) / 4
So it combines 3 VWMAs with the VWAP and divides that number by 4 to give us a moving average. Then we add new levels above and below that moving average to get our channels. The channels are separated by the % deviation you choose in the settings. For tighter bands, lower the percentage deviation and for wider bands, increase the percentage deviation.
The fattest line in the middle is the main moving average and you can expect price to regularly return to this level. The thick lines are the main moving average plus or minus the percentage deviation you have set. There are 10 levels in each direction from the main moving average. The is also a thin short term moving average as well with a custom calculation. It takes 4 different length moving averages that are weighted and 4 more that are volume weighted and divides the total by 8.The lines will be green when price is above the line and red when price is below the line. The thin white line is the VWAP on its own.
These lines will act as dynamic support and resistance so you can scalp them back and forth. These levels work so well because they are volume weighted and the algos hedge their positions back and forth constantly.
For best results, use this indicator on tickers with the highest volume and trading action as the price will stick to these levels better when the big money players are hedging. Some great tickers for this indicator are APPL, SPY, BTC, ETH.
All colors and linewidths can be customized in the settings easily as well as turning off the VWAP or short moving average and adjusting the percentage deviation for the channels.
***MARKETS***
This indicator can be used on all markets, including stocks, crypto, futures and forex.
***TIMEFRAMES***
This indicator can be used on all timeframes.
***TIPS***
Try using numerous indicators of ours on your chart for extra confirmation. Our favorites to pair with these bands are the Scalper Ribbon and Trend Friend Signals. The 3 combined give you a lot of extra confirmation on whether the market is going to reverse at these levels.
Shadow Compact Volume BETAThis indicator will give you an overview of the trading volume of 1 candle, useful for new traders (This indicator will be updated more in the future). The current calculation method does not give any any trading signals!If you find it interesting or want to support the development of this indicator ,You can support me a cup of tea via the following link:
paypal.me/paulslim
Enjoy new good days!
Weight Gain 4000 - (Adjustable Volume Weighted MA) - [mutantdog]Short Version:
This is a fairly self-contained system based upon a moving average crossover with several unique features. The most significant of these is the adjustable volume weighting system, allowing for transformations between standard and weighted versions of each included MA. With this feature it is possible to apply partial weighting which can help to improve responsiveness without dramatically altering shape. Included types are SMA, EMA, WMA, RMA, hSMA, DEMA and TEMA. Potentially more will be added in future (check updates below).
In addition there are a selection of alternative 'weighted' inputs, a pair of Bollinger-style deviation bands, a separate price tracker and a bunch of alert presets.
This can be used out-of-the-box or tweaked in multiple ways for unusual results. Default settings are a basic 8/21 EMA cross with partial volume weighting. Dev bands apply to MA2 and are based upon the type and the volume weighting. For standard Bollinger bands use SMA with length 20 and try adding a small amount of volume weighting.
A more detailed breakdown of the functionality follows.
Long Version:
ADJUSTABLE VOLUME WEIGHTING
In principle any moving average should have a volume weighted analogue, the standard VWMA is just an SMA with volume weighting for example. Actually, we can consider the SMA to be a special case where volume is a constant 1 per bar (the value is somewhat arbitrary, the important part is that it's constant). Similar principles apply to the 'elastic' EVWMA which is the volume weighted analogue of an RMA. In any case though, where we have standard and weighted variants it is possible to transform one into the other by gradually increasing or decreasing the weighting, which forms the basis of this system. This is not just a simple multiplier however, that would not work due to the relative proportions being the same when set at any non zero value. In order to create a meaningful transformation we need to use an exponent instead, eg: volume^x , where x is a variable determined in this case by the 'volume' parameter. When x=1, the full volume weighting applies and when x=0, the volume will be reduced to a constant 1. Values in between will result in the respective partial weighting, for example 0.5 will give the square root of the volume.
The obvious question here though is why would you want to do this? To answer that really it is best to actually try it. The advantages that volume weighting can bring to a moving average can sometimes come at the cost of unwanted or erratic behaviour. While it can tend towards much closer price tracking which may be desirable, sometimes it needs moderating especially in markets with lower liquidity. Here the adjustability can be useful, in many cases i have found that adding a small amount of volume weighting to a chosen MA can help to improve its responsiveness without overpowering it. Another possible use case would be to have two instances of the same MA with the same length but different weightings, the extent to which these diverge from each other can be a useful indicator of trend strength. Other uses will become apparent with experimentation and can vary from one market to another.
THE INCLUDED MODES
At the time of publication, there are 7 included moving average types with plans to add more in future. For now here is a brief explainer of what's on offer (continuing to use x as shorthand for the volume parameter), starting with the two most common types.
SMA: As mentioned above this is essentially a standard VWMA, calculated here as sma(source*volume^x,length)/sma(volume^x,length). In this case when x=0 then volume=1 and it reduces to a standard SMA.
RMA: Again mentioned above, this is an EVWMA (where E stands for elastic) with constant weighting. Without going into detail, this method takes the 1/length factor of an RMA and replaces it with volume^x/sum(volume^x,length). In this case again we can see that when x=0 then volume=1 and the original 1/length factor is restored.
EMA: This follows the same principle as the RMA where the standard 2/(length+1) factor is replaced with (2*volume^x)/(sum(volume^x,length)+volume^x). As with an RMA, when x=0 then volume=1 and this reduces back to the standard 2/(length+1).
DEMA: Just a standard Double EMA using the above.
TEMA: Likewise, a standard Triple EMA using the above.
hSMA: This is the same as the SMA except it uses harmonic mean calculations instead of arithmetic. In most cases the differences are negligible however they can become more pronounced when volume weighting is introduced. Furthermore, an argument can be made that harmonic mean calculations are better suited to downtrends or bear markets, in principle at least.
WMA: Probably the most contentious one included. Follows the same basic calculations as for the SMA except uses a WMA instead. Honestly, it makes little sense to combine both linear and volume weighting in this manner, included only for completeness and because it can easily be done. It may be the case that a superior composite could be created with some more complex calculations, in which case i may add that later. For now though this will do.
An additional 'volume filter' option is included, which applies a basic filter to the volume prior to calculation. For types based around the SMA/VWMA system, the volume filter is a WMA-4, for types based around the RMA/EVWMA system the filter is a RMA-2.
As and when i add more they will be listed in the updates at the bottom.
WEIGHTED INPUTS
The ohlc method of source calculations is really a leftover from a time when data was far more limited. Nevertheless it is still the method used in charting and for the most part is sufficient. Often the only important value is 'close' although sometimes 'high' and 'low' can be relevant also. Since we are volume weighting however, it can be useful to incorporate as much information as possible. To that end either 'hlc3' or 'hlcc4' tend to be the best of the defaults (in the case of 24/7 charting like crypto or intraday trading, 'ohlc4' should be avoided as it is effectively the same as a lagging version of 'hlcc4'). There are many other (infinitely many, in fact) possible combinations that can be created, i have included a few here.
The premise is fairly straightforward, by subtracting one value from another, the remaining difference can act as a kind of weight. In a simple case consider 'hl2' as simply the midrange ((high+low)/2), instead of this using 'high+low-open' would give more weight to the value furthest from the open, providing a good estimate of the median. An even better estimate can be achieved by combining that with 'high+low-close' to give the included result 'hl-oc2'. Similarly, 'hlc3' can be considered the basic mean of the three significant values, an included weighted version 'hlc2-o2' combines a sum with subtraction of open to give an estimated mean that may be more accurate. Finally we can apply a similar principle to the close, by subtracting the other values, this one potentially gets more complex so the included 'cc-ohlc4' is really the simplest. The result here is an overbias of the close in relation to the open and the midrange, while in most cases not as useful it can provide an estimate for the next bar assuming that the trend continues.
Of the three i've included, hlc2-o2 is in my opinion the most useful especially in this context, although it is perhaps best considered to be experimental in nature. For that reason, i've kept 'hlcc4' as the default for both MAs.
Additionally included is an 'aux input' which is the standard TV source menu and, where possible, can be set as outputs of other indicators.
THE SYSTEM
This one is fairly obvious and straightforward. It's just a moving average crossover with additional deviation (bollinger) bands. Not a lot to explain here as it should be apparent how it works.
Of the two, MA1 is considered to be the fast and MA2 is considered to be the slow. Both can be set with independent inputs, types and weighting. When MA1 is above, the colour of both is green and when it's below the colour of both is red. An additional gradient based fill is there and can be adjusted along with everything else in the visuals section at the bottom. Default alerts are available for crossover/crossunder conditions along with optional marker plots.
MA2 has the option for deviation bands, these are calculated based upon the MA type used and volume weighted according to the main parameter. In the case of a unweighted SMA being used they will be standard Bollinger bands.
An additional 'source direct' price tracker is included which can be used as the basis for an alert system for price crossings of bands or MAs, while taking advantage of the available weighted inputs. This is displayed as a stepped line on the chart so is also a good way to visualise the differences between input types.
That just about covers it then. The likelihood is that you've used some sort of moving average cross system before and are probably still using one or more. If so, then perhaps the additional functionality here will be of benefit.
Thanks for looking, I welcome any feedack
Volume Risk Avoidance IndicatorPrice Pattern Analysis is the core of trading. But price patterns often fails.
VRAI (Volume Risk Avoidance Indicator) shows Volume Pressure, so that you can avoid volume-based risks.
For example, never short when you see green (buying pressure). Never long when you see red (selling pressure).
You still need to pick good price patterns, because the crossover of volume pressure is not reliable.
Enjoy!
Volume Profile, Pivot Anchored by DGTVolume Profile (also known as Price by Volume ) is an charting study that displays trading activity over a specified time period at specific price levels. It is plotted as a horizontal histogram on the finacial isntrumnet's chart that highlights the trader's interest at specific price levels. Specified time period with Pivots Anchored Volume Profile is determined by the Pivot Levels, where the Pivot Points High Low indicator is used and presented with this Custom indicator
Finally, Volume Weighted Colored Bars indicator is presneted with the study
Different perspective of Volume Profile applications;
Anchored to Session, Week, Month etc : Anchored-Volume-Profile
Custom Range, Interactive : Volume-Profile-Custom-Range
Fixed Range with Volume Indicator : Volume-Profile-Fixed-Range
Combined with Support and Resistance Indicator : Price-Action-Support-Resistance and Volume-Profile
Combined with Supply and Demand Zones, Interactive : Supply-Demand-and-Equilibrium-Zones
Disclaimer : Trading success is all about following your trading strategy and the indicators should fit within your trading strategy, and not to be traded upon solely
The script is for informational and educational purposes only. Use of the script does not constitutes professional and/or financial advice. You alone the sole responsibility of evaluating the script output and risks associated with the use of the script. In exchange for using the script, you agree not to hold dgtrd TradingView user liable for any possible claim for damages arising from any decision you make based on use of the script
PJBG - HMA Smoothed VWMA [HMASVWMA]Problem: (1) lag of traditional MA's, (2) lack of Volume data in traditional MA's, and (3) choppiness of traditional MA's.
Solution: apply hull formula tick to tick, simply at a factor of 1:1.
Result: Smooth and fast MA that has volume data baked in it.
Benefit: See trend changes fast, and if it is supported by volume. Pleasant to the eyes.
Explanatory note: hull ma's generally cannot be volume weighted because the volume will spike the line tremendously.
Volume Profile - Custom Range, Interactive by DGTVolume Profile - Custom Range aims to display trading activity at specific price levels over user defined Custom Range of trading. Start and End Time is Interactive , they can be adjusted simply by clicking on the chart and drag the lines to specify the desired custom range. Same as is with the drawing tools available in TV
Please note, while switching between timeframes or switching to different instruments with different exchange timezones you may need to adjust the locations in case the plotting is not displied
Volume Profile - Custom Range is plotted as two horizontal histograms on the finacial isntrumnet's chart that highlights the trader's common interest at specific price levels as well as aims to reveal dominant party of who is in control, bulls or bears
You are also invated to galnce at Volume-Profile-and-Volume-Indicator , Anchored-Volume-Profile , and Price Action-Support-Resistance for different perspective of Volume Profiles
Special thanks to everyone who commented and presented their valuable suggestions
Disclaimer: Trading success is all about following your trading strategy and the indicators should fit within your trading strategy, and not to be traded upon solely
The script is for informational and educational purposes only. Use of the script does not constitutes professional and/or financial advice. You alone the sole responsibility of evaluating the script output and risks associated with the use of the script. In exchange for using the script, you agree not to hold dgtrd TradingView user liable for any possible claim for damages arising from any decision you make based on use of the script
Anchored Volume Profile by DGTAnchored Volume Profile aims to display trading activity at specific price levels over specified anchored periods of trading, where anchor period can be set to auto or users can specify anchor periods of their interest (Day (Session), Week, Quarter or Year)
Anchored Volume Profile is plotted as two horizontal histograms on the finacial isntrumnet's chart that highlights the trader's common interest at specific price levels as well as aims to reveal dominant party, bulls or bears
You are invited to glance at Vol Profile and Price Action-Support-Resistance studies
Disclaimer: Trading success is all about following your trading strategy and the indicators should fit within your trading strategy, and not to be traded upon solely
The script is for informational and educational purposes only. Use of the script does not constitutes professional and/or financial advice. You alone the sole responsibility of evaluating the script output and risks associated with the use of the script. In exchange for using the script, you agree not to hold dgtrd TradingView user liable for any possible claim for damages arising from any decision you make based on use of the script
Volume Profile and Volume Indicator by DGTVolume Profile (also known as Price by Volume) is an charting study that displays trading activity over a specified time period at specific price levels. It is plotted as a horizontal histogram on the finacial isntrumnet's chart that highlights the trader's interest at specific price levels.
The histogram is used by traders to predict areas of support and resistance. Price levels where the traded volume is high could be assumed as support and resistance levels.
Price may experience difficulty moving above or below areas with large bars. Usually there is a great deal of activity on both the buy and sell side and the market stays at that price level for a great deal of time
It is advised to use volume profile in conjunction with other forms of technical analysis to maximize the odds of success
Light version of Volume Profile is added to Price Action - Support & Resistance by DGT
RedK Volume-Accelerated Directional Energy Ratio (RedK VADER)The Volume-Accelerated Directional Energy Ratio (VADER) makes use of price moves (displacement) and the associated volume (effort) to estimate the positive (buying) and negative (selling) "energy" behind the scenes, enabling traders to "read the market action" in more details and adjust their trading decisions accordingly.
How does VADER work?
------------------------------------
I have always been a fan of technical analysis concepts that are simple, and that integrate both price action and volume together - The concept behind VADER is really a simple one.
Let's walk though it as we avoid getting too technical:
Large price moves that are associated with large volume means buyers (if the move is up) or sellers (when the move is down) are serious and are "in control" of the action
On the other hand, when the price moves are small but with large volume, it means there's a fight, or more of a balance of energy, between buying and selling.
Also when large price moves are associated with relatively limited volume, there's a lack of "energy" from either buyers or sellers - and moves likes these are usually short-lived.
The analogy with VADER, is that we look at price moves (change of close between 2 bars) as the displacement (or action result) and the associated volume as the "effort" behind this action -- Combining these 2 values together, the displacement and the effort, gives us a representation or a proxy of the underlying energy (in a specific direction).
when both values (displacement and effort) are high, then the resulting energy is high - and if one of these values are low, the resulting energy is low.
we then take an average of that relative energy in each direction (positive = buying and negative = selling) and calculate the net energy.
note that we're approaching the analogy here from a trading perspective and not from physics perspective :) -- we can be forgiven if the energy calculation in physics is different ..
VADER Plots
---------------------
the blue line with crosses represents the positive energy - or the buying strength
the orange line with circles represents the negative energy - or the selling strength
the thick Green / Red main line plot represents the net energy - and generally the main signal to be looking out for is when that line crosses 0 up or down - but i find it also very valuable to keep an eye on the individual energy lines as they sometimes "tell a story" like we see in the chart above,
Volume Calculation:
----------------------------
- VADER by default is a volume-weighted indicator - it uses the volume associated with change in bar close value (Full mode) as an accelerator in the calculation of the directional energy
- VADER introduces another method of integrating volume, by considering "relative" or "differential" volume (Relative mode) - in this mode, we consider the ratio of volume above the minimum volume observed within a "lookback" length - so practically, ignoring the minimum volume. in other words, if a price move is associated with very low volume, it gets very low "volume accelerator" (close to 0) and if the move is associated with very large volume, it gets the maximum volume accelerator (1 or close to 1) - The relative mode of volume calculation magnifies volume effect and ignores the low volume values that may just act as noise. test both modes and find which one works better for you.
- VADER also has the ability to work without volume (volume calculation = None) - and will revert to that mode when used with instruments that have no volume data. In that mode, VADER will behave similar to an RSI (but not exactly like it given the underlying calculation is different)
- We can also setup VADER at a specific resolution / timeframe that is different than the chart.
Using VADER & Other Thoughts
----------------------------------------
The main signal to look out for, is when VADER's Green / Red line crosses the zero line.
Green (above zero) represents that the net energy is with the buyers and we should favor long positions
Red (below zero) reflects that the sellers have control and we should favor short positions (or consider to close longs)
*** However, VADER should be used as a *secondary indicator* - given the big influence of volume on the calculation - VADER doesn't directly track price trend or momentum - VADER needs to be used in the context of other indicators that show trend and momentum - i would suggest you combine VADER with Moving Averages or other trend tracking indicators on the price chart, MACD, RSI and / or other trend and momentum indicators you're already familiar with.
Suggested setup:
There's more to add to VADER in future versions - alerts, control level, maybe improve visuals... etc - please share your feedback as you start experimenting with VADER.. good luck! (and of course, May the Force be with you :) )
NEXT Trend Delta Moving AverageOverview:
Trend Delta Moving Average (TDMA) is a composite moving average, driven by an algorithm that tracks real-time trends in price, volume, and various changes (delta) between the two. TDMA is low lagging but filtered (smoothed) MA type, with a sometimes predictive slope (via price divergence). This indicator allows you to plot one or two TDMA lines, as well as their crossovers, expressed in the form of long/short signals.
NASDAQ 100 Futures ( CME_MINI:NQ1! ) 1-minute
This Nasdaq futures example shows both TDMA lines and their crossover signals.
Tesla ( NASDAQ:TSLA ) 1-minute
If you trade price / MA crossovers or use moving averages as part of a broader trading system, you have the option of displaying a single TDMA line without any crossover signals (arrows) by ticking Plot TDMA1 Only checkbox and unticking Plot TDMA Crossovers . Great for breakout stocks like TSLA.
TDMA vs Other Moving Averages
We spent a good amount of effort developing and differentiating Trend Delta Moving Average (TDMA) from other moving averages. We wanted a responsive MA algo that considered price and action, and that incoporated user-controlled lagless filtering (smoothing). Below is a comparison between TDMA (purple) and several popular MA types, including Exponential (blue), Simple (red), and Hull (teal). All MA lengths set to 50.
Lagless Smoothing
You may use the Trendiness input parameter to control the amount of smoothing applied to individual or both TDMA lines. Lower values (emphasis on more recent trends) produce vertically tighter slopes, with TDMA following price action more closely, while higher values (emphasis on more longer term trends) relax the slope, without introducing horizontal (time) lag.
Input Parameters:
Length TDMA1 - length of the first Trend Delta Moving Average (TDMA)
Length TDMA2 - length of the second TDMA
Trendiness TDMA1 - the amount of trend weighting added to the first TDMA line (lower = more recent trend, higher = longer term trend)
Trendiness TDMA2 - the amount of trend weighting added to the second TDMA line (lower = more recent trend, higher = longer term trend)
Source - data used for calculating the MAs, typically Close, but can be used with other price formats and data sources as well.
Offset - shifting of the TDMA lines forward (+) or backward (-).
Plot TDMA1 Only - when checked, will only plot a single TDMA line (TDMA1)
Plot TDMA Crossovers - when checked, will plot an up arrow (long signal) when TDMA1 crosses over TDMA2, and a down arrow (short signal) when TDMA1 crosses under TDMA2.
Alerts
Here is how to set price crossing TDMA1 (or TDMA2) alerts: open a TradingView chart, attach NEXT Trend Delta Moving Average (TDMA), right-click on chart -> Add Alert. Condition: Symbol (e.g. NQ) >> Crossing >> NEXT Trend Delta Moving Average (TDMA) >> TDMA1 >> Once Per Bar Close.
Linear Regression, Volume WeightedProduces deviation lines based upon linear regression of volume adjusted price with the option to clean the data of outliers.
The regression line is more accurate than standard linear regression as each data point is effectively a volume unit (share) and the total number of data points is the total volume from the beginning to end.
Haye VWAPThis is VWAP but instead of average price resetting daily, you choose the VWAP reset period.
You could choose an Hourly VWAP, or a 2D VWAP, the choice is yours.
To show the functionality compared to normal VWAP, the below shows Haye VWAP (White) and normal VWAP (red), both set to Daily timeframes and on a Daily Chart.
As you can see, they're identical.
Then the following shows a 15min chart, with VWAP set to 15min timeframe and Haye VWAP set to Daily.
Again, notice they're identical because even when you change the timeframe of the regular VWAP, it still "resets" the average price calculation Daily.
Finally you can see what happens when we change the Haye VWAP period, the average price calculation resets based on the period you choose.
In this case Haye VWAP and regular VWAP are both set to 240 (4Hour) on a 5min chart.
The regular VWAP is displaying the 4Hour data of the VWAP (which resets Daily).
The Haye VWAP (in White) is displaying the Volume Weighted Average Price of the 5min bars, resetting every 4Hours.
This allows us to use the principles of VWAP but apply it to shorter (or longer) timeframes. For example, you could have a VWAP that resets hourly, or a longer VWAP that resets every 2Days.