Moving Average ZonesImagine bollinger bands, but instead with multiple customizable moving averages.
MAZ contains moving averages that act as support and resistance. This can lead to potential use for stop loss and take profit decision-making along with potential signs of reversals.
Features
Areas of Confluence
Display Options
Data Window
Default Settings (with Data Window)
Areas of Confluence
In the photo above, every touch inside a zone increases the brightness of the zone, strengthening the confluence of the zone.
Zones will disappear after a while if no touches have occurred in between a zone within the specified lookback period.
Unterstützung und Widerstand
CryptoverseThis Indicator dynamically generates and charts Pivot Points, Support and Resistance Lines, Trend Channels and even Rsi Divergences in every market and every time period.
While it helps you identify your entry points, stop loss and take positions, it certainly does not include trading signals and trading strategy.
Bonus: the indicator contains ema21, ema50, ema100 and ema200 to support the lines created. If you wish, you can change the EMA values in the settings.
Recommendation: RSI is included in the indicator codes in order to detect divergences dataally, but it is not displayed on the chart. I recommend adding an additional RSI indicator to keep track of past and current potential divergences.
USER MANUAL:
----------------------------------------------
General Settings:
Pivot Period: This field determines how many candles before and after a candle should be controlled in order to be able to determine the top and bottom points on the chart.
Support and Resistance Lines and Trend Channels formed on the chart are created by calculating the Pivot points formed according to the period determined here. (Default value: 6)
Pivot Source: Determines the pivot points to be created according to the value of the relevant candle.
(Default and Recommended: closing)
----------------------------------------------
Support And Resistance Settings:
Custom Bars Back: This area allows you to specify how many pivot points from the current candle to the previous candle to create support resistance lines on the Chart. The default value is the last 500 candles.
*Note: The more old candles are checked, the more support and resistance lines will appear. This may prevent you from making sound determinations on the chart.*
Current Bar Decrease: This field works integrated with Custom Bars Back. By subtracting the current candle by the specified number, it provides the formation of lines without including those candles.
Default value: It is set to 0 to include current data.
Example: If Custom Bars Back: 500 and Current Bar Decrease: 10, Support and Resistance lines are created by considering 500 candles before the last 10 candles without including the last 10 candles on the chart.
Show S/R Lines: This field allows you to show or hide the Support and Resistance lines at any time.
Auto Simplification: This field is marked by default. It allows the Simplification Steps value to be determined automatically within the code according to the time period and current volatility of the relevant parity. (It is recommended to use the default version.)
Simplification Steps: This field allows you to get more understandable lines by simplifying the Support and Resistance lines based on Pivot points. If a simplification is not done, the lines to be formed with only the pivot points will be too many and this creates a dirty and useless appearance on the chart.
Each 1 digit you enter as a step combines the lines that are close to each other at a value of 0.01% and creates a common line.
Example: If you enter the number 10 as Steps, it will form a single common line from lines close together, starting at 0.01% respectively. It will continue to increase by 0.02%, 0.03%, 0.04% in its next steps. For the number 10, it will complete its loop by combining lines within the last remaining lines that are as close as 0.1% to each other and creating new lines from their midpoints.
The deafult value is 14. (Max. simplifies lines with closeness up to 1.4%.)
Important Note: If Auto Simplification is on, the entered value has no meaning. The Indicator performs simplification operations automatically. If you want to manage these steps manually, you can turn off Auto Simplification and enter your own value.
S/R Lines Color: Allows you to specify the color of the lines.
Label Location: Allows you to determine how many candles ahead the information label formed for each line will be positioned.
Line Label Descriptions:
Line: It is the price value that the line coincides with.*
Distance: Shows the percentage distance of the line from the current price.
▲ : Shows the percentage distance from the line above it.
▼ : Shows the percentage distance from the line below it.
Strength: Indicates the total number of steps the process has taken during the simplification process. The height of the number indicates the strength of resistance and support in the close price range.
C. Width: stands for Channel Width. It shows the percentage value between the highest price and the lowest price on the past candle as many candles specified by Custom Bars Back.
S. Steps: stands for Simplification Steps. Indicates the number of simplification steps applied. A value of 150 in the image indicates that a 1.5% simplification range has been applied.
----------------------------------------------
Trend Channels Settings:
Show All Trend Lines: Allows you to show and hide trend channels.
Hide Old Trend Lines: If you enable it, it will hide channels created in the past except for Current Trend channels.
Helper Line Format: Allows the auxiliary line that converts a trendline to a channel to be drawn based on percentage or price.
Note: There may be cases where the auxiliary lines do not provide full parallelism when using large time intervals by preferring a percentage.
Up Trend Color: Indicates the color of the Up Trend channel.
Down Trend Color: Specifies the color of the Downtrend channel.
Show Up Trend Overflow, Show Down Trend Overflow:
When the price closes above or below the trend channels, it provides awareness with the help of a text on the chart. Colors can be adjusted according to preference.
----------------------------------------------
RSI Divergences Settings:
This indicator gives you information about 4 different divergences. You can customize the divergence views with the show and hide options.
Bullish Regular, Bullish Hidden, Bearish Regular and Bearish Hidden.
Green divergences from the bottom of the graph represent bullish, and red divergences above the graph represent bearish.
Important note: Seeing a mismatch label definitely indicates that there is a mismatch between prices and rsi, but a mismatch does not always indicate a change in price.
Potential Divergence:
The indicator not only shows you past divergences, but also informs you of potential divergences based on the current status of the chart.
A potential divergence may not turn into a true one if the price flow continues to increase or decrease in the same direction. But all divergences seen in the past must have been shown as potential divergences beforehand.
Rsi Length, Rsi Source: Allows you to change settings for RSI values typically embedded within the indicator.
Note: Pivot Source and RSI Source using the same type of candle data ensures that divergences are displayed correctly.
----------------------------------------------
EMA Settings:
The indicator allows you to use 4 different EMA data in addition to Support and Resistance lines, Trend Channels and RSI divergences. By default, 21, 50, 100 and 200 are used. You can change the EMA values and colors in the Settings section, or you can use the show hide options in the Style section.
Dynamic Fibonacci RetracementA simple fibonacci retracement tool that dynamically updates itself based on current price and previous retracement values.
Features the essential aspects of the built-in tool and more.
Auto Trendline
Auto Reversal
Auto Level Adjustment
Labels indicating retracement value
Customizable lookback range
The top and bottom levels will auto-adjust according to where price currently is, which will also affect fibonacci levels as it progresses.
Dynamic Linear Regression Oscillator | AdulariDescription:
This dynamic linear regression oscillator visualizes the general price trend of specific ranges in the chart based on the linear regression calculation, it automatically determines these ranges with pivot detection. The central line of the indicator is the baseline of the linear regression itself. This is a good tool to use to determine when a price is unusually far away from its baseline. The lines above or below it are overbought and oversold zones. These zones are based on the high or low of the range, in combination with the set multipliers.
The overbought and oversold lines indicate support and resistance; when the prices stay outside these levels for a significant period of time, a reversal can be expected soon. When the oscillator's value crosses above the signal or smoothed line the trend may become bullish. When it crosses below, the trend may become bearish.
This indicator is quite special, as it first determines price ranges using pivot detection. It then uses the middle of the range to determine how far the current price is from the baseline. This value is then rescaled compared to a set amount of bars back, putting it into relevant proportions with the current price action.
How do I use it?
Never use this indicator as standalone trading signal, it should be used as confluence.
When the value crosses above the signal this indicates the current bearish trend is getting weak and may reverse upwards.
When the value crosses below the signal this indicates the current bullish trend is getting weak and may reverse downwards.
When the value is above the middle line this shows the bullish trend is strong.
When the value is below the middle line this shows the bearish trend is strong.
When the value crosses above the upper line this indicates the trend may reverse downwards.
When the value crosses below the lower line this indicates the trend may reverse upwards.
Features:
Oscillator value indicating how far the price has currently deviated from the middle of the range. Proportioned to data from a set amount of bars ago.
Signal value to indicate whether or not the price is abnormally far from the middle of the range.
Horizontal lines such as oversold, overbought and middle lines, indicating possible reversal zones.
Automatic range detection using pivots.
Built-in rescaling functionality to ensure values are proportionate with the latest data.
How does it work? (simplified)
1 — Calculate the middle of the range.
2 — Define whether the current price is above the middle of the range or below.
3 — If above the middle of the range, calculate the difference of the current high and the middle line. If below, calculate the difference of the current low and the middle line.
4 — Smooth the value using a set moving average type.
5 — Rescale the value to proportionate it with the latest data.
Trading ChannelTrading Channel aims to be a canvas on which to develop any strategy that the user feels comfortable with.
The greatest utility of the script lies in the fact that it plots a channel over the price action, as a support and resistance pivot, within which the price action develops.
It is a script of maximum simplicity in concept and development, but at the same time presents robust support to the price action and a quick visual aid complementary to any indicators that the user works with, feels comfortable with, and uses as a basis for their strategies.
The script includes the following features (most of them disabled by default, available for potential use without the need to add additional indicators):
Fast SMA
Medium SMA
Slow SMA (disabled)
Fast EMA (disabled)
Medium EMA (disabled)
Slow EMA (disabled)
Pivot
Pivot SMA
P Multiplier
Set of resistance and support pivots according to the studies of John L. Person (R3, R2, R1, S1, S2, S3 and midpoints) (disabled by default)
Channel for the current time period in use
Channels for extended time periods (disabled by default)
Various trend, momentum, and overbought/oversold indicating labels (note that the calculations for their representation are based on SMA's even though EMA's are visualized).
SMA's/EMA's
Both are available as both are used as basic indicators for different types of strategies. The default selection of SMA's in this case is based on the fact that the script development is largely based on the studies shared by John L. Person in the area of pivots and by Bill Williams in the area of fractals. Note also that for that same reason the various trend, momentum, and overbought/oversold indicating labels are calculated based on them.
Set of resistance and support pivots
They are included as a consultation tool especially for the higher time periods. They can be used to mark the most interesting supports/resistances and not lose sight of them while operating in lower time periods. Marking monthly, weekly, and daily pivots can be very useful. Additionally, marking S1 and R2 for bullish trends, S1 and R1 for ranges, and S2 and R1 for bearish trends can provide an even more precise framework to work on.
P Multiplier
It is set by default at 4, and is the basis for being able to consider during the use of a specific time frame, the price action with respect to higher time frames. It is the multiplier used for the generation of channels for extended time periods.
Channel for the current time period in use
It is a channel formed by the maximum and minimum closing of the last 21 periods. This value is modifiable and its adjustment depends on the asset under study. 24/7 markets show good results with this adjustment (in the case of BTC really good).
This channel represents a pivot in the form of a yellow middle line, with its support and resistance extremes on the upper green and lower red lines. The same green and red lines, referenced this time to the maximum, are added and serve as possible stop-loss marks.
Channels for extended time periods
Enabling the maximum and minimum channels for extended periods can provide a better idea of the price situation (it is recommended to disable the channel in use and enable the upper one for consultation, it provides a better vision).
Identifying labels:
Following a summary explanation for possible long entries, the same but opposite should be considered for possible short entries:
Small green arrow under candle: indicates possible upward trend (pivot above pivot SMA)
Large green arrow under candle: indicates upward trend (pivot above pivot SMA and above fast SMA)
Green triangle over candle: indicates channel breakout, possible upward momentum (represented as a fractal as its concept is the same)
Green/red arrows at the bottom of the chart: intended to confirm the validity of a signal (should doubt green indications with red lower arrow and vice versa)
Green/red dots at the bottom of the chart: red represents areas of strong resistance and green signals of strong support (with red dots, proceed with caution despite green signals, and vice versa)
Comments
It is emphasized that the basic and most useful functionality of this script is to provide a reliable base on which to develop any strategy, as a framework for working.
If the identifying labels are used, it should be taken into account that the earliest will always be the most reliable and valuable, but their confirmation will always depend on the user's strategy.
Its use in conjunction with the "Pivot Position for Trading Channel" indicator can serve as a base for the development of different strategies, by providing indication of the relative position of the price within the channel.
This script is just a consultation tool with didactic goals, it should not be used as an investment recommendation and the information provided should not be relied upon as such.
------------------------
Trading Channel pretende ser un lienzo sobre el que desarrollar cualquiera que sea la estrategia con la que el usuario se sienta más cómodo.
La mayor utilidad del script radica en que se traza sobre la acción del precio un canal, a modo de pivotes de soporte y resistencia, dentro del cual se desarrolla la acción del precio.
Se trata de un script de máxima sencillez en concepto y desarrollo, pero que a la vez presenta un soporte robusto a la acción del precio y una ayuda rápida visual complementaria a cualquieras que sean los indicadores con los que el usuario trabaje, se sienta más cómodo y utilice como base de sus estrategias.
El script incluye las siguientes funcionalidades (la mayoría desactivadas por defecto, disponibles para su potencial uso sin necesidad de añadir indicadores adicionales):
- SMA rápida
- SMA media
- SMA lenta (desactivada)
- EMA rápida (desactivada)
- EMA media (desactivada)
- EMA lenta (desactivada)
- Pivote
- SMA de pivote
- Multiplicador de P
- Conjunto de pivotes resistencia y soporte de acuerdo a los estudios de John L. Person (R3, R2, R1, S1, S2, S3 y puntos medios) (desactivados por defecto)
- Canal para el periodo temporal en uso
- Canales para periodos temporales extendidos (desactivados por defecto)
- Diversas etiquetas indicativas de cambios de tendencia, de impulso y de sobrecompra y sobreventa (nótese que los cálculos para su representación están basados en SMA's aunque se visualicen EMA's).
SMA's/EMA's
Ambas disponibles pues tanto unas como otras son utilizadas como indicadores básicos para diferentes tipos de estrategias. La selección de SMA's por defecto en este caso se basa en que las bases para desarrollo del script son en gran medida los estudios compartidos por John L. Person en el área de pivotes y de Bill Williams en el área de los fractales. Nótese también que por esa misma razón las diversas etiquetas indicativas de cambios de tendencia, impulso y sobrecompra/sobreventa se calculan en base a ellas.
Conjunto de pivotes resistencia y soporte
Se incluyen como herramienta de consulta sobre todo para los periodos temporales más altos. Pueden utilizarse para marcar los soportes/resistencias de más interés y no perderlos de vista mientras se opera en periodos de tiempo más bajos. De acuerdo a los estudios de John L. Person, marcarse los pivotes mensuales, semanales y diarios puede resultar de mucha utilidad. Adicionalmente, marcar S1 y R2 para tendencias alcistas, S1 y R1 para rangos, y S2 y R1 para tendencias bajistas puede proporcionar un marco aún más preciso sobre el que trabajar.
Multiplicador de p
Está fijado por defecto en 4, y es la base para poder considerar durante el uso de una franja temporal concreta, la acción del precio respecto a franjas temporales superiores. Es el multiplicador utilizado para la generación de los canales para periodos temporales extendidos.
Canal para el periodo temporal en uso
Se trata de un canal conformado por los cierres máximos y mínimos de los últimos 21 periodos. Este valor es modificable y su ajuste depende del activo en estudio. Mercados 24/7 muestran buenos resultados con este ajuste (en el caso de BTC realmente buenos).
Este canal representa en cierta manera un pivote en forma de línea intermedia amarilla, con sus extremos de soporte y resistencia en las líneas verdes superior y roja inferior. Se añaden las mismas líneas verdes y rojas, referenciadas esta vez a los máximos, que sirven como posibles marcas de stop-loss.
Canales para periodos temporales extendidos
Habilitar los máximos y mínimos de canales de periodos extendidos puede proporcionar una mejor idea de la situación del precio (se recomienda deshabilitar el canal en uso y habilitar el superior para consulta, proporciona una mejor visión).
Etiquetas identificativas:
A continuación explicación resumida para posibles entradas en largo, lo mismo pero de modo opuesto debería considerarse para posibles entradas en corto:
Flecha verde pequeña bajo vela: indica inicio de tendencia en alza (pivote por encima de SMA de pivote y ambos por encima de SMA rápida)
Flecha verde grande bajo vela: indica tendencia en alza (pivote por encima de SMA de pivote y ambos por encima de SMA rápida y media)
Triángulo verde sobre vela: indica rotura de canal, posible impulso al alza (representado a modo de fractal pues su concepto es el mismo)
Flechas verdes/rojas a pie de gráfico: pretenden confirmar la validez de una señal (debería dudarse de las indicaciones verdes con flecha inferior roja y viceversa)
Puntos verdes/rojos a pie de gráfico: los rojos representan áreas de fuerte resistencia y los verdes de fuerte soporte (con puntos rojos, proceder con cautela pese a señales verdes, y viceversa)
Comentarios
Se insiste en que la funcionalidad básica y de mayor utilidad de este script es proporcionar una base confiable sobre la que desarrollar cualquier estrategia, a modo de marco de trabajo.
Si se hace uso de las etiquetas identificativas, debe tenerse en cuenta que las más prematuras siempre serán las más confiables y valiosas, pero que su confirmación siempre dependerá de la estrategia por parte del usuario.
Su uso en conjunción al indicador "Pivot Position for Trading Channel" puede servir de base para el desarrollo de diferentes estrategias, al proporcionar indicación de la posición relativa del precio dentro del canal.
Este script es solo una herramienta de consulta con objetivos didácticos, no debe ser utilizado como recomendación de inversión y no se debe confiar en ella como tal.
ICT Killzones [LuxAlgo]This script highlights ICT Killzones on the chart along with Fibonacci retracements constructed from each Killzone's price range, allowing traders to find more optimal entries.
Settings
Killzone Retracements
Show Retracements: Determines whether Fibonacci retracements are displayed on the chart.
Extend: Determines if the retracements are extended outside the Killzone.
Reverse: Switches the maximum and minimum levels for the calculation of the retracements.
Other settings allow disabling as well as changing the retracement value and color.
Usage
Killzones are introduced by forex trader ICT and represent different time intervals that aims at offering optimal trade entries. Killzones include:
New York Killzone (7:9 ET)
London Open Killzone (2:5 ET)
London Close Killzone (10:12 ET)
Asian Killzone (20:00 ET)
Note that using timeframes superior to 1h can highlight incorrect intervals
Fibonacci retracements on an active Killzone are subject to changes, if no Killzones are active then the associated Fibonacci retracements will stay at their current level.
Disabling specific Killzones while having extended retracements will allow them to extend further. In the image above the New York and Asian Killzones are disabled.
True Trend Average BandsThis is the indicator I am most proud of. After reading Glenn Neely's book "Mastering Eliott Waves" / "Neowave" and chatting with @timwest who got acknowledged by Neely, we came up with the idea of an moving average which does calculate the real average price since a trend started. Addionally I adapted a method from Neely Neowave and Tim Wests TimeAtMode to not force a timeframe on a chart but instead let the charts data decide which timeframe to use, to then calculate the real average price since the trend started.
It took me a while to get this right and coded, so take a moment and dive deeper and you might learn something new.
We assume that the price is in multiple trends on multiple timeframes, this is caused by short term traders, long term traders and investors who trade on different timeframes. To find out in which timeframe the important trends are, we have to look out for significant lows and highs. Then we change the timeframe in the chart to a value so that we have 10 to 20 bars since the significant low/high. While new bars are printed, and we reach more than 20 bars, we have to switch to a higher timeframe so we have 10 to 20 bars again. In the chart you see two significant trends: a downtrend on the 3 week timeframe and an uptrend from the 2 month timeframe. Based on the logic I have described, these are the two important timeframes to watch right now for the spx (there is another uptrend in the yearly chart, which is not shown here).
Now that we understand how to find the important timeframes, let's look what the magic in this script is that tells us the real average price since a trend started.
I developed a new type of moving average, which includes only the prices since a trend started. The difference to the regular sma is that it will not include prices which happened before the significant low or high happened. For example, if a top happened in a market 10 days ago, the regular sma20 would be calculated by 10 bars which happened before the top and 10 bars which happened after the top. If we want to know the average price of the last 10 bars we manually have to change the ma20 to the ma10 which is annoying manual work, additionally even if we use the ma10 in this case, and we look at yesterday's bar the ma10 will include 9 bars from after the top and one bar before the top, so the ma10 would only show the real average price for the current bar which is not what we want.
To come up with a solution to this problem, the True Trend Average searches for the lowest/highest bar in a given period (20 bars). Then starts to calculate the average value since the low/high. For example: if the price reaches a new 20 day high and then trades below it, the day of the high will be the sma1, the day after it's the sma2, ... up to the maximum look back length.
This way, we always know what the average price would have been if someone sold/bought a little bit every bar of his investment since the high/low.
Why is this even important? Let's assume we missed selling the top or buying the low, and think it would have been at least better to buy/sell a little bit since the new trend started. Once the price reaches the true trend average again, we can buy/sell, and it would be as good as selling/buying a little bit every day. We find prices to buy the dip and sell the bounce, which are as good as scaling in/out.
There is a lot more we can learn from these price levels but I think it is better to let you figure out yourself what you can learn from the information given by this indicator. Think about how market participants who accumulate or distribute feel when prices are above or below certain levels.
Now that we understand this new type of moving average, let's look into the lines we see in the chart:
The upper red band line shows the true trend average high price since the last significant top within 20 bars.
The lower red band line shows the true trend average hl2 price since the last significant top within 20 bars.
The lower green band line shows the true trend average low price since the last significant low within 20 bars.
The upper green band line shows the true trend average hl2 price since the last significant low within 20 bars.
The centerline is the average between the upper red band and the lower green band.
The teal lines show 1 standard deviation from the outer bands.
Before today only a few people had access to this indicator, now that it is public and open source, I am curious if you will find it useful and what you will do with it. Please share your findings.
/edit: The chart only shows the 3week timeframe so here are the other two trends from the 2month and 1year timeframe
Quickfingers Luc base scanner - version 2This is my second implementation of a Pine Script Quickfingers Luc (QFL) base scanner that I have published on Trading View. QFL base scanners seek to provide buy signals according to the QFL trading strategy. To profitably trade using this script you should be familiar with the QFL trading strategy, scaling in and out of positions, and money risk management.
Background
All the QFL base identification Pine Scripts that I have inspected to date use a simple candlestick pattern of two lower lows followed by two higher lows to identify a base. Some scripts may combine this with a volume indicator as well. In practice, I found the results of this approach to be somewhat unreliable. The candlestick pattern may identify some significant bases, may identify minor bases (that should not be traded), but at the same time miss other significant bases entirely!
My first QFL base scanner sought to use Pine Script’s built in ta.lowest and ta.highest functions to identify bases and peaks. This approach depended on the time period selected to find the lowest lows and highest highs. This approach can be problematic because significant bases may be formed outside the nominated time period, leading to the identification of minor bases within the time period. I have left the first version of my QFL base scanning script in the Trading View indicators because it uses a different approach to this script that other people may still find useful.
My second version of the QFL base scanner does not use the Pine Script ta.lowest and ta.highest functions, and therefore does not rely on nominating a time period to look back through data.
User inputs
This script steps through the price data to find the following patterns that are used to confirm bases and peaks.
Base – bounce of x% above previous base confirms that base
Peak – fall of y% below previous peak confirms that peak
Buy signal – fall of z% below the base signals a buy signal.
x%, y% and z% are user configurable through the script settings. Small percentages will provide more, but riskier, buy signals; larger percentages will provide fewer, but safer, buy signals.
The script identifies QFL bases and buy signals and marks them on the price chart. These are able to be turned on and off in the script settings. The settings also allow the user to turn on plots for peaks, lowest lows and highest highs. These are not useful for applying the QFL trading strategy, but are calculations used in finding bases and can be useful for the user to understand what the script is doing in the background.
Troubleshooting
If looking at the past script results, you may think that the script is perfectly timing entry points at the bottom of market dips. This is NOT the case. The script is actually showing buy signals when the price falls z% below the PREVIOUS base. The current base is only retrospectively marked some periods later once the reversal is confirmed – a solid line marks a confirmed base in real time; a dotted line retrospectively repaints the line to the actual base. New bases are not tradeable using this script, but a percentage fall from the previous base is – this is the QFL trading strategy.
Pine Script may flag that this script has a repainting issue. Pine Script defines repainting as, “script behavior causing historical vs realtime calculations or plots to behave differently.” In the case of this script, bases are confirmed once the price has bounced x% off the low. The script then repaints a dotted line from the base that has been identified in real time (with a solid line) back to the point in the price data where the base actually occurs. The dotted line only aids in visual identification of the base, and does not impact on the real time identification of bases. A similar repainting issue occurs for identifying peaks. I have identified the lines in the script that cause this repainting. These lines can be commented out without affecting the buy signals generated by the script, but you will also lose the visual pinpointing of historical bases and peaks.
The user may find price charts where they think that the script has not correctly identified a base or peak. Usually, careful measurement will reveal that the price chart has not confirmed a base or peak by moving x% or y% from the previous base or peak respectively.
And before you ask, yes, Trading View alerts work with this script.
Enjoy.
Volume-Weighted Price Levels (VWPL)Introduction:
In this script, we will be creating an indicator that plots horizontal lines on the chart for each unique price in a given range, and colors them based on the volume of that price.
Explanation:
First, we define the input "Length" as an integer. This will determine the number of bars back from the current bar to include in the range.
We then create two arrays: "price" and "vol." The "price" array will store all the unique prices in the given range, and the "vol" array will store the corresponding volumes for those prices.
Using a for loop, we iterate through the range of bars and check if the current close price is already included in the "price" array. If it is not, we add it to the array and also add the corresponding volume to the "vol" array. If it is already included, we find the index of that price in the "price" array and add the current volume to the volume stored at that index in the "vol" array.
After the for loop, we find the maximum volume in the "vol" array and use that to find the corresponding price in the "price" array. This will be the price at which we draw the horizontal line.
We then create an array of lines called "lines" and, using another for loop, we iterate through the "price" array and add a line to the "lines" array for each price. The color of each line is determined by the volume of that price, using a color gradient from blue (lowest volume) to red (highest volume).
Finally, we use an if statement to check if the current bar is the last bar in the chart, and if it is, we use another for loop to iterate through the "lines" array and delete all the lines. This is to prevent the lines from being carried over to the next bar and potentially being plotted multiple times.
Conclusion:
This script can be useful for visualizing the price levels with the highest volume in a given range, as well as seeing how volume is distributed among different price levels. It can be helpful for identifying areas of significant buying or selling pressure.
Trading Channel for BTCThe goal is to visualize, through basic but robust information, a channel that frames the price action, whose referenced limits and lines are indicative of potential entries and exits.
It is a simple but enormously reliable base for the development of different strategies.
The parameters for the script have been optimized for BTC. It shows good results in all time frames.
Red lines: support of closures and lows (indicative of potential points of purchase).
Green lines: resistance of closures and highs (indicative of potential points of sale).
Orange-gray line: proposed stop loss for long positions, at a ratio of 2:1.
Yellow line: midpoint of channel (as a reference for trend change detection or even possible take-profits).
White line: 8-period simple moving average (SMA).
Gray line: 21-period SMA.
Pink line: standard pivot.
Purple line: 3-period simple moving average pivot.
Blue lines (deactivated by default): standard range of support and resistance pivots (according to the studies of John L. Person).
A channel of support and resistance indicative of potential entry points is shown, both for short and long positions. The channel is based on the closures and the lowest and highest lows and highs of the last 21 periods, shifted one period.
In addition to showing the channel of support and resistance, the script also includes the display of two SMAs (simple moving averages) of 8 and 21 periods, as well as standard and 3-period simple moving average pivots, which can be used as support for entry decisions.
The script allows the user to develop more or less aggressive strategies, conditioning the entries to the price's contact, closure, or distance from the different proposed support and resistance lines, and confirming the same entries through possible SMA and/or pivot crosses, and exits in the same way.
The standard range of support and resistance lines, deactivated by default, is a consultation tool for the higher time frames (month, week, day) for the location of strong supports and resistances that may recommend or, on the contrary, discourage the execution of entries.
The strong point of the script is the visualization of a reliable channel within which the price action develops with basic and repetitive behavior: when the price touches one of the limits, it then goes to the opposite one. Based on that foundation, with the help of the indicators that are most familiar and/or reliable for the user, an infinity of strategies suitable for all types of traders can be developed.
This script is just a consultation tool with didactic goals, it should not be used as an investment recommendation and the information provided should not be relied upon as such.
----------
Se pretende visualizar por medio de información básica pero robusta, un canal que enmarca la acción del precio, cuyos límites y líneas referenciadas son indicativos de potenciales entradas y salidas.
Resulta una base simple pero enormemente confiable para el desarrollo de diferentes estrategias.
Los parámetros para el script han sido optimizados para BTC. Muestra buenos resultados en todos los marcos temporales.
Líneas rojas: soportes de cierres y mínimos (indicativas de puntos potenciales de compra).
Líneas verdes: resistencias de cierres y mínimos (indicativas de puntos potenciales de venta).
Línea gris anaranjada: propuesta de stop loss para posiciones en largo, a razón de 2:1.
Línea amarilla: punto medio de canal (como referencia para detección de cambios de tendencia o incluso posibles take-profit).
Línea blanca: SMA (promedio móvil simple) de 8 periodos.
Línea gris: SMA de 21 periodos.
Línea rosa: pivote estándar.
Línea morada: pivote de media simple de 3 periodos.
Líneas azules (desactivadas por defecto): abanico de pivotes de soportes y resistencias estándar (según los estudios de John L. Person).
Se muestra un canal de soportes y resistencias indicativas de puntos potenciales de entradas tanto en corto como en largo. El canal se basa en los cierres y los mínimos y máximos más bajos y más altos de los últimos 21 periodos, desplazados un periodo.
Además de mostrar el canal de soportes y resistencias, el script incluye también la visualización de dos SMA's (promedios móviles simples) de 8 y 21 periodos, así como pivotes estándar y de media simple de 3 periodos, que se pueden utilizar como apoyo para las decisiones de entrada.
El script permite al usuario desarrollar diferentes estrategias más o menos agresivas, condicionando las entradas al contacto, al cierre o al alejamiento del precio respecto a las diferentes líneas de soporte y resistencia propuestas, pudiendo confirmar las mismas entradas por posibles cruces de SMA's y/o pivotes, y las salidas de igual manera.
El abanico de soportes y resistencias estándar, desactivadas por defecto, son herramienta de consulta para los marcos temporales más altos (mes, semana, día) para localización de resistencias y soportes fuertes, que pudieran recomendar o, por el contrario, desaconsejar la ejecución de entradas.
El punto fuerte del script es la visualización de un canal confiable dentro del que se desarrolla la acción del precio con un comportamiento básico y repetitivo: al tocar el precio uno de los límites, se dirige después al opuesto. Sobre esa base, con la ayuda de los indicadores que resulten más conocidos y/o confiables para el usuario, se pueden desarrollar infinidad de estrategias adecuadas para todos los tipos de trader.
Este script es solo una herramienta de consulta con objetivos didácticos, no debe ser utilizado como recomendación de inversión y no se debe confiar en ella como tal.
Support and Resistancewhat is "Support and Resistance"?
it is a support and resistance indicator.
what it does?
it draw support and resistance zones on the chart.
how it does it?
It determines the zones where the price leaves with a big candle after going horizontal for a while as support or resistance zones according to the price movement direction. while doing this, it compares the size of the candles and the elapsed time.
how to use it?
Red zones represent resistance and green zones represent support. You can buy in the support zone or sell in the resistance zone. my advice is to make your own interpretation by taking into account the price movement with different indicators. they are considered useful if there is a closure beyond the zones. otherwise, they continue to be shifted to the right.
notice: As new zones are created, old ones may disappear. so it might be wise to draw boxes using drawing tools where the old zones are.
Support and resistance are very important concepts for technical analysis. so I am thinking of updating and improving this indicator many times in the long run. but I couldn't wait long to post it.
examples:
Support Resistance - Dynamic v2 w/ Timeframe optionThis script is a modification from the awesome "Support Resistance - Dynamic v2" by @LonesomeTheBlue
This script is very similar to the original indicator mentioned above, but with a modification that, in my opinion, would be very useful for many traders. It enables the option to choose different timeframe to calculate the S/R levels. Very often, traders would like to use higher timeframes to define S/R levels, rather than using the same timeframe that they are trading at. For example, if trading at 5min, we often use 15min, 30min or 1hr timeframe to define our S/R levels.
For example, below shows S/R levels from three different timeframes:
Hope you find value in this indicator~ Enjoy~
Bagang Pivot Zones | Supply & Demand, Support & ResistanceBagang Pivot Zones detects imbalances from classic reversal and momentum price actions.
Imbalances create pivot zones, a.k.a Supply & Demand / Support & Resistance / Orderblock zones.
Use Cases
1. Traders using Supply & Demand theory can quickly pinpoint imbalance zones created by BUY-to-SELL and SELL-to-BUY candles.
2. Trend Following traders can systematically catch and follow a trend based on pivot zones analysis.
3. Breakout traders can easily target pivot zones’ breakout and breakdown.
4. Take the guesswork out of risk management: manage stop-loss precisely behind pivot zones.
5. Analyze contrary pivot zones to set realistic profit targets.
Objectivity
By only comparing OHLC values to identify notable price actions, Bagang Pivot Zones avoids derived calculations with subjective parameters.
Chart Issue
If the chart zooms out after adding an indicator, right-click the price scale and toggle "Scale price chart only” on.
Moving Average Support and ResistanceThis indicator takes a moving average, creates an envelope, and analyzes how frequently the moving average and its deviations act as areas of support or resistance. Using this information, you can determine how strong the moving average is as a support or resistance. For example, if the 200 SMA with a 5% range and 1% buffer has an S/R ratio of 1:1.5, then the 200 SMA is acting as resistance more frequently than support. This indicator uses the "buffer" as an envelope extension. The best way to think of this buffer is to envision areas where false breakouts and stop runs may occur. Use this indicator to experiment with different moving averages, ranges, and buffers to find the best combination for your trading style.
Anchored VWAP BandSimple script to anchor vwap to a drag and drop spot on the chart and display it as a band instead of a line.
the AVAP Band displays:
1. The AVWAP using High as the source
2. The AVWAP using OHLC4 as the source
3. The AVWAP using Low as the source
This is just a different way of visualising VWAP from an anchored point in time (Band vs Line)
Volume profile zonesHi all!
This script calculates and shows the volume profile for the range of a higher timeframe candle. It then shows support or resistance (/supply or demand) zones based on the volume profiles with the most volume. The defaults are just my preferred settings so feel free to play with them! Also feel free to let me know about bugs and features. I already have a list of features to make, e.g.:
base on pivots
more info zone calculations, e.g. breaks and retests, virgin point of control etc.
add alerts
get rid of getPriceLevels()
get rid of _barVolumeProfile prefix
handle realtime
...
Best of trading luck!
Imbalance Detector [LuxAlgo]This indicator detects and highlights market imbalances alongside a dashboard returning information about their frequency of occurrence and their fill percentage. Imbalances included in this script are Fair Value Gaps (FVG), Opening Gaps (OG) and Volume Imbalances (VI).
Alerts are available for the occurrences of all market imbalances.
Settings
Imbalances
Each imbalance has the same settings layout:
Imbalance: Enable/disable the detection of the specific imbalance.
Min Width: If enabled, requires the imbalance area width to be greater than the specified value. This minimum width can be expressed in points, percentages or ATR multiples.
Extend: Extend imbalances by a specified number of bars.
Dashboard
Show Dashboard: Enable/disable the dashboard on the chart.
Dashboard Location: Location of the dashboard on the chart.
Dashboard Size: Size of the dashboard.
Usage
Market imbalances are part of the many concepts available to price action traders and highlight areas where there is a disparity between supply and demand.
It is common to see price come back to these areas and traders often use them as supports and resistances but also as targets.
Details
The script can detect three distinct types of imbalances described below.
Fair Value Gaps
Fair Value Gaps (FVG) are three candle formations characterized by a gap between the wicks of the non-adjacent candles in the formation.
A bullish FVG is characterized by a gap between the current price low and the 2 bars anterior price high, and a bearish FVG is characterized by a gap between the current price high and the 2 bars anterior price low.
Opening Gaps
Opening Gaps (OG) are imbalances characterized by non-existent activity within a specific price range.
A bullish OG occurs when the current price low is greater than the previous high, a bearish OG occurs when price high is lower than the previous price low.
Opening Gaps primarily occur in closing markets, as such they are less common in the cryptocurrency market.
Most of the time an Opening Gap will also be accompanied by a Fair Value Gap, in order to avoid clutter the indicator will not detect Fair Value Gaps if Opening Gaps are enabled and if an Opening Gap has been detected
Volume Imbalances
Volume Imbalances (VI) are characterized by a price discontinuity between the opening price and previous close, but unlike Opening Gaps we do not see nonexistent activity within a certain price range.
A bullish VI occur when both the opening and closing prices are superior to the previous closing price, with the current price low overlapping the previous price high. A bearish VI occur when both the opening and closing prices are inferior to the previous closing price, with the current price high overlapping the previous price low.
Because Volume Imbalances can occur excessively on markets with frequent gaps, we make use of an additional condition for filtering out less significant imbalances. Bullish VI's will require the previous price high to be lower than the opening price, while bullish VI's will require the previous price low to be higher than the opening price.
Zones DetectorThis indicator highlights supply and demand zones.
Method to detect the zones:
1.- The body of the candle is calculated and it is checked how many times it can be repeated in its highest or lowest wick. If the body of the candle is repeated N number of times (Min. Factor) in any of its wicks, it is taken as an indecision zone.
2.- The subsequent candles are reviewed (Confirmation Bars) to determine if the zone is of supply or demand. For demand zones, subsequent prices must be above the minimum price of the indecision zone and for supply zones, subsequent prices must be below the maximum price of the indecision zone.
3.- The previous average volume of N periods (Periods) to the indecision zone is calculated and check that has a minimum percentage change (Min. Volume Change) with respect to the indecision zone and its subsequent candles (Confirmation Bars).
If the previous steps are met, the zone will be highlighted with a green color for demand (Zones/Demand) and red for supply (Zones/Supply), for the indecision zones (identified by point 1) they will be highlighted in gray (Zones/Indecision)
Invalid zones are automatically hidden from the chart, using methods such as: "wick" and "close".
Settings
Indecision
Min. Factor: Set the number of times that the body of the candle must be repeated in its wicks. High values will be stronger indecision zones, but fewer will be found, low values will find more zones.
Invalidation Method: Method used to automatically invalidate zones. It can be "wick" or "close".
Confirmation Bars: Defines the number of candles used to confirm an indecision zone found
Volume
Min. Volume Change(%): Percentage of minimum change in volume (+/-) that the zone must have to be displayed
Previous Periods: Number of previous periods to be used to calculate the average volume prior to the indecision zone.
Zones
Show Last.- Number of zones (demand, supply, indecision) to be shown.
Demand.- Color to highlight the demand zones
Supply.- Color to highlight the supply zones
Indecision.- Color to highlight the indecision zones
Use
The highlighted supply and demand zones can be used as support or resistance to place orders.
Dynamic Linear Regression ChannelsPlots new linear regression channels from points where a previous channel is broken thus keeping the length of bars in the trend dynamic. Regression channels are useful in detecting trend changes, support and resistance levels and to trade mean reversions.
Note: Setting higher values of upper and lower deviation may result in error if the price never breaks the channel and the script references too many bars than supported.
Sessions [LuxAlgo]This indicator shows when user set sessions are active and returns various tools + metrics using the closing price within active sessions as an input. Users have the option to change up to 4 session times.
The indicator will increasingly lack accuracy when the chart timeframe is higher than 1 hour.
Settings
Sessions
Enable Session: Allows to enable or disable all associated elements with a specific user set session.
Session Time: Opening and closing times of the user set session in the hh:mm format.
Range: Highlights the associated session range on the chart.
Trendline: Returns the associated session trendline on the chart.
Mean: Returns the associated session mean average on the chart.
VWAP: Returns the associated session volume weighted average price on the chart.
Ranges Settings
Range Area Transparency: Transparency of the area highlighting sessions ranges.
Range Outline: Highlights the borders of the session range area.
Range Label: Shows the session label at the mid-point of the session interval.
Dashboard
Show Dashboard: Enables sessions dashboard on the chart.
Advanced Dashboard: Returns more information regarding user set sessions on the dashboard.
Dividers
Show Session Divider: Highlights active sessions using intervals on the bottom of the chart (this can lead to less responsive charts)
Show Daily Divider: Highlights days on the chart.
Usage
This tool is versatile and allows the user to perform a wide variety of tasks all focusing on highlighting and analyzing price movements within a specific user set session in a periodic fashion.
Significant forex trading sessions are used by default, but the users are free to choose the opening and closing time of their choices.
Using ranges can indicate which sessions returned the most volatile price movements.
Trendlines can be useful to estimate the underlying trend of a specific session, but they can also offer a quick way to see which session started a trend reversal.
The session Mean highlights the equilibrium level within a session, extrapolating these levels can provide potential support and resistances levels of interest.
Finally, users can use the sessions VWAP's for real time applications, using them as trailing supports and resistances.
Using The Advanced Dashboard
The advanced dashboard returns useful information regarding the user set sessions. Each dashboard elements are described below:
Status: Highlights whether the user set session is active (open) of inactive (closed).
Trend: Shows correlation coefficient between the session prices and a linear sequence of values. Values above 0 indicates an up-trending session, while values under 0 indicates a down-trending session. Values closer to (1, -1) indicates a more trending session.
Volume: Shows accumulated volume within the session
σ (Standard Deviation): Shows standard deviation of the session, while this value is not bounded it can be useful to compare it with the other ones to see which session was the most volatile.
Note that when a session becomes inactive the value on the dashboard will hold until the specific session becomes active again.
Gann Spiral / Square of 9The Gann Spiral, more commonly known as the Square of 9 is one of the most well known tools that Gann used. Today, it is most commonly used to find possible support and resistance levels, and possible reversals in time.
This indicator is a more flexible version of the traditional Gann Spiral / Square. This is achieved by allowing you to change:
Price and Time direction
The timeframe
How often to draw lines based on degrees
Toggles for Price and Time
Price and Time line customization
How to use:
1 - Select your desired starting value of Price and Time.
2 - Choose the direction of Price and Time.
3 - Choose the amount of lines to display.
4 - Choose how often for lines to be drawn (Rotation Degree Value).
==================================================================
Side Note:
This uses a more proper and more accurate formula to "navigate the square". (Sqr x + 2)^2 is not the formula used, but rather (Sqr x + 1)^2.
If you wish to use the formula you're used to, change Full Revolution Value to 180.
The reasoning behind this formula change is because I re-created the square in the form of an actual spiral. The issue with such a conversion is that the formula used to construct it uses one Pi. If you understand circles, you should know that we're off by 180 degrees. A full rotation is 360, not 180.
Correcting for this error requires a slight but important change in the formula, that being +1 instead of +2. This not only corrects it to fit for a proper spiral, but also makes it easier to use fractions. 1/360 results in 1 degree. This slight formula change makes it incompatible when used on the actual Square of 9, however it is technically the more accurate formula.
Fixed Fibonacci Support ResistanceI took the formula of the fibonacci from LonesomeTheBlue and made this script. You can take a look at his indicator here:
When you first add the indicator on the chart, click on the chart to select the first date and then the second date. It will then calculate the fibonacci support and resistance of the range you choose. You can also choose the date inside the inputs.
Be sure the first date is before the second date, otherwise it won't be able to show the fibonacci. If that happen, choose a correct date in the inputs.
CAT Month Opening RangeA trading range which is formed during the first three trading day of any month sets an important "Month Opening Range".
The lowest price made during the first three trading days can be considered the Monthly Support level (see the green line drawn by the indicator).
The highest price made during the first three trading days can be considered the Monthly Resistance level (see the red line drawn by the indicator).
In an Up trending market price tends to break over the upper edge of the Month Opening Range and keep moving higher at the very least until the middle of that month.
In an Up trending market once price broke out of the Month Opening Range, the Monthly Resistance level tends to work as a support.
In a Down trending market price tends to break under the lower edge of the Month Opening Range and keep moving higher at the very least until the middle of that month.
In a Down trending market once price broke under the Month Opening Range, the Monthly Support level tends to work as a resistance
There are may ways to use that instrument:
(1) Trend Confirmation.
The first three days of a month tends to bring volatile trading. The market sets boundaries for the following four trading weeks.
Once the range has been set, swing traders may wait for the market to break out of the range and consider that direction of the prevailing trend direction.
(2) Short "Failed Breakout" setup
Quite often price breaks out of the Month Opening Range on the fourth or fifth trading day of a month but then drops back into the range.
That failed breakout quite often is followed by decline back down to the Month Support level (the lower edge of the Month Opening Range).
(3) Long "Failed Breakdown" setup
Quite often price breaks down under the Month Support on the fourth or fifth trading day of a month but then pops back up over the Monthly Support.
That failed breakdown quite often is followed by a rally targeting to retest the Monthly Resistance (the red line).
The indicator generates signals, trade set-ups and alerts that are for educational and hypothetical purposes only and shall not be considered trade recommendations.
Any signals or trading setups drawn by the indicator is not to be construed as an offer to sell or the solicitation of an offer to buy, nor is it to be construed as a recommendation to buy, hold or sell (short or otherwise) any security. All users of the indicator must determine for themselves what specific investments to make or not make and are urged to consult with their own independent financial advisors with respect to any investment decision.