Smoothing ATR bandThere are two bands calculated with the ATR and I added "Smoothing" into the script.
Smoothing ATR with multiplier can display two bands above and below the price.
We can ONLY find some ATR bands in Community Scripts with "Basic" setting which is used to set Stop Loss.
And yet , Smoothing ATR with multiplier is capable of making traders manifestly recognize OverBought & OverSold.
FurtherMore, I added a condition with "plotshape", which is "Stop Hunt"
Stop Hunt is an absolutely usual strategy to clean the leverage and it always makes high volatility moves.
When high> above band and close< above band , long signal, it means it had been abundantly bought but the larger traders weren't satisfied; therefore, they quickly sold out to lower the price. The sell condition is on the contrary.
The signals mainly make traders manifestly recognize OverBought & OverSold.
Volatility
Intraday Volatility BarsThis script produce a volatility histrogram by bar with the current volatility overlayed.
The histogram shows cumulative average volatility over n days.
And the dots are todays cumulative volatility.
In other words, it calculates the True Range of each bar and adds it to todays value.
This script is build for intraday timeframes between one and 1440 minutes only.
I use this to show me when volatility is above/below/equal to the average volatility.
When the dots are above the histogram then it is a more volatile day, and vice versa.
Recognizing a more volatile day as early as possible can be an advantage for daytrader.
Days that start with higher volatility seems to continue to increase relative to the past few days. Or when midday volatility rises it seems to continue as well.
Happy Trading!
Coppock Curve w/ Early Turns [QuantVue]The Coppock Curve is a momentum oscillator developed by Edwin Coppock in 1962. The curve is calculated using a combination of the rate of change (ROC) for two distinct periods, which are then subjected to a weighted moving average (WMA).
History of the Coppock Curve:
The Coppock Curve was originally designed for use on a monthly time frame to identify buying opportunities in stock market indices, primarily after significant declines or bear markets.
Historically, the monthly time frame has been the most popular for the Coppock Curve, especially for long-term trend analysis and spotting the beginnings of potential bull markets after bearish periods.
The signal wasn't initially designed for finding sell signals, however it can be used to look for tops as well.
When the indicator is above zero it indicates a hold. When the indicator drops below zero it indicates a sell, and when the indicator moves above zero it signals a buy.
While this indicator was originally designed to be used on monthly charts of the indices, many traders now use this on individual equities and etfs on all different time frames.
About this Indicator:
The Coppock Curve is plotted with colors changing based on its position relative to the zero line. When above zero, it's green, and when below, it's red. (default settings)
An absolute zero line is also plotted in black to serve as a reference.
In addition to the classic Coppock Curve, this indicator looks to identify "early turns" or potential reversals of the Coppock Curve rather than waiting for the indicator to cross above or below the zero line.
Give this indicator a BOOST and COMMENT your thoughts!
We hope you enjoy.
Cheers!
Divergance Based on Vortex IndicatorThe Vortex-Based Divergence Indicator represents a groundbreaking approach to analyzing market dynamics within the realm of technical analysis. Drawing inspiration from the concept of vortices and their cyclical patterns, this indicator strives to illuminate potential divergence points within financial markets, providing traders with valuable insights for informed decision-making.
At its foundation, the Vortex-Based Divergence Indicator builds upon the principles of the Vortex Indicator, a well-established tool for gauging momentum and identifying potential trend reversals. However, this innovative indicator goes a step further by focusing on the divergences that can occur between the Vortex Indicator and the actual price movements.
Divergences, which arise when the direction of an indicator's movement contradicts the direction of price action, hold paramount significance within the Vortex-Based Divergence Indicator. By integrating this indicator with other renowned oscillators, such as the Relative Strength Index (RSI) or the Moving Average Convergence Divergence (MACD), traders can augment their analytical capabilities significantly.
These complementary oscillators can corroborate or validate the signals generated by the Vortex-Based Divergence Indicator. For instance, when the Vortex-Based Divergence Indicator hints at a potential trend reversal, cross-referencing this insight with the RSI's overbought or oversold levels can enhance the accuracy of the prediction. Likewise, employing the MACD to confirm momentum shifts in conjunction with the Vortex Indicator's signals can provide a more comprehensive view of market dynamics.
It's crucial to emphasize the importance of synergy when combining these indicators. Rather than relying solely on the Vortex-Based Divergence Indicator, incorporating other oscillators acts as a checks-and-balances system, reducing false signals and enhancing the overall reliability of the trading strategy. However, prudent traders also recognize that no indicator or combination thereof is foolproof. Additional factors, such as fundamental analysis and market news, should also be considered to achieve well-rounded trading decisions.
In essence, the Vortex-Based Divergence Indicator's integration with established oscillators like RSI and MACD offers traders a powerful toolkit to navigate complex market landscapes. By leveraging the strengths of each indicator and cross-referencing their insights, traders can elevate their trading strategies to new heights of accuracy and effectiveness.
Multiple Percentile Ranks (up to 5 sources at a time)This indicator is a visual percentile rank indicator that can display 1 to 5 sources at one time.
The options:
“Sources”
Choose the number of sources you would like to display. The minimum is 1, the maximum is 5.
“Label percent position”
The label for the current percentage of where the source candle ranks.
“Label position”
This displays the source/s you’ve selected, and the chosen bottom rank % and top rank %.
“Label text size”
Displays the text size of all labels.
“Display current % labels”
Switches the labels on/off only for the current percentage rank of each source.
Source options:
ATR: Average True Range
CCI: Commodity Channel Index
COG: Centre of Gravity
Close: closing price
Close Percent: close percentage from previous close
Dollar Value: volume * (high * low * close / 3)
EOM: Ease of Movement: how much volume it takes to move the price in a certain direction
OBV: On-Balance Volume
RANGE: percentage range of the close price
RSI: Relative Strength Index
RVI: Relative Vigor Index
Time Close: if you select the 1 second timeframe it will provide the gap of time between each 1 second close
Volume: each bar’s volume
Volume (MA): volume moving average
Source # where # is the number of the source. Selects the source you’d like.
Ma Length is the number of previous candles to consider when calculating the moving average of the source. Note, the “MA Length” only applies to sources that have the “(MA)” at the end of their name.
Bottom % is the bottom percentage rank of the source you’ve selected. This is a filter to display the candle line graph in red once the percentage rank is equal to the percentage you’ve chosen or below.
Top % is the top percentage rank of the source you’ve selected. This is a filter to display the candle line graph in green once the percentage rank is equal to the percentage you’ve chosen or higher.
A simple example of how to use the indicator:
Select the dropdown menu for source 1 and select volume.
As the candles populate, it will look at previous candles and assign a percentage rank of where the candles are in relation to previous candles.
*Note, the way Tradingview works is it will populate the first candle the chart was active, and continue on. So, let’s say the 3rd candle was the highest volume day. This candle will show up as 100%. If the next day, the 4th candle has an even higher volume, it will show up as 100% also, the previous candles won’t “repaint” to other values and are instead set based on when they were confirmed. So, this indicator works best when there are a lot of previous candles to compare itself to.
To use the bottom % rank filter enter a percentage such as 5%. As it comes across a candle that is 5% or less compared to previous volume candles, then the line graph will shade in red.
The same can be said for the top % rank. So, if you want to see the line graph change to green when it comes across the top 99th percentile rank of volume bars, then set the top % rank to 1% and it will give you extremely high-volume bars in green instead of blue.
Volatility Price RangeThe Volatility Price Range is an overlay which estimates a price range for the next seven days and next day, based on historical volatility (already available in TradingView). The upper and lower bands are calculated as follows:
The Volatility for one week is calculated using the formula: WV = HV * √t where:
WV: one-week volatility
HV: annual volatility
√: square root
t: the time factor expressed in years
From this formula we can deduce the weekly volatility WV = HV * √(1 / 52) = HV / 7.2 where 52: weeks in a year.
The daily volatility DV = HV * √(1 / 365) = HV / 19.1 where 365: days in a year.
To calculate the lower and upper value of the bands, the weekly/daily volatility value obtained will be subtracted/added from/to the current price.
TTP SuperTrend ADXThis indicator uses the strength of the trend from ADX to decide how the SuperTrend (ST) should behave.
Motivation
ST is a great trend following indicator but it's not capable of adapting to the trend strength.
The ADX, Average Directional Index measures the strength of the trend and can be use to dynamically tweak the ST factor so that it's sensitivity can adapt to the trend strength.
Implementation
The indicator calculates a normalised value of the ADX based on the data available in the chart.
Based on these values ST will use different factors to increase or reduce the factor use by ST: expansion or compression.
ST expansion vs compression
Expanding the ST would mean that the stronger a trends get the ST factor will grow causing it to distance further from the price delaying the next ST trend flip.
Compressing the ST would mean that the stronger a trends get the ST factor will shrink causing it to get closer to the price speeding up the next ST trend flip.
Features
- Alerts for trend flip
- Alerts for trend status
- Backtestable stream
- SuperTrend color gets more intense with the strength of the trend
Advanced Weighted Residual Arbitrage AnalyzerThe Advanced Weighted Residual Arbitrage Analyzer is a sophisticated tool designed for traders aiming to exploit price deviations between various asset pairs. By examining the differences in normalized price relations and their weighted residuals, this indicator provides insights into potential arbitrage opportunities in the market.
Key Features:
Multiple Relation Analysis: Analyze up to five different asset relations simultaneously, offering a comprehensive view of potential arbitrage setups.
Normalization Functions: Choose from a variety of normalization techniques like SMA, EMA, WMA, and HMA to ensure accurate comparisons between different price series.
Dynamic Weighting: Residuals are weighted based on their correlation, ensuring that stronger correlations have a more pronounced impact on the analysis. Weighting can be adjusted using several functions including square, sigmoid, and logistic.
Regression Flexibility: Incorporate linear, polynomial, or robust regression to calculate residuals, tailoring the analysis to different market conditions.
Customizable Display: Decide which plots to display for clarity and focus, including normalized relations, weighted residuals, and the difference between the screen relation and the average weighted residual.
Usage Guidelines:
Configure the asset pairs you wish to analyze using the Symbol Relations group in the settings.
Adjust the normalization, volatility, regression, and weighting functions based on your preference and the specific characteristics of the asset pairs.
Monitor the weighted residuals for deviations from the mean. Larger deviations suggest stronger arbitrage opportunities.
Use the difference plot (between the screen relation and average weighted residual) as a quick visual cue for potential trade setups. When this plot deviates significantly from zero, it indicates a possible arbitrage opportunity.
Regularly update and adjust the parameters to account for changing market conditions and ensure the most accurate analysis.
In the Advanced Weighted Residual Arbitrage Analyzer , the value set in Alert Threshold plays a crucial role in delineating a normalized band. This band serves as a guide to identify significant deviations and potential trading opportunities.
When we observe the plots of the green line and the purple line, the Alert Threshold provides a boundary for these plots. The following points explain the significance:
Breach of the Band: When either the green or purple line crosses above or below the Alert Threshold , it indicates a significant deviation from the mean. This breach can be interpreted as a potential trading signal, suggesting a possible arbitrage opportunity.
Convergence to the Mean: If the green line converges with the purple line , it denotes that the price relation has reverted to its mean. This convergence typically suggests that the arbitrage opportunity has been exhausted, and the market dynamics are returning to equilibrium.
Trade Execution: A trader can consider entering a trade when the lines breach the Alert Threshold . The return of the green line to align closely with the purple line can be seen as a signal to exit the trade, capitalizing on the reversion to the mean.
By monitoring these plots in conjunction with the Alert Threshold , traders can gain insights into market imbalances and exploit potential arbitrage opportunities. The convergence and divergence of these lines, relative to the normalized band, serve as valuable visual cues for trade initiation and termination.
When you're analyzing relations between two symbols (for instance, BINANCE:SANDUSDT/BINANCE:NEARUSDT ), you're essentially looking at the price relationship between the two underlying assets. This relationship provides insights into potential imbalances between the assets, which arbitrage traders can exploit.
Breach of the Lower Band: If the purple line touches or crosses below the lower Alert Threshold , it indicates that the first symbol (in our example, SANDUSDT ) is undervalued relative to the second symbol ( NEARUSDT ). In practical terms:
Action: You would consider buying the first symbol ( SANDUSDT ) and selling the second symbol ( NEARUSDT ).
Rationale: The expectation is that the price of the first symbol will rise, or the price of the second symbol will fall, or both, thereby converging back to their historical mean relationship.
Breach of the Upper Band: Conversely, if the difference plot touches or crosses above the upper Alert Threshold , it suggests that the first symbol is overvalued compared to the second. This implies:
Action: You'd consider selling the first symbol ( SANDUSDT ) and buying the second symbol ( NEARUSDT ).
Rationale: The anticipation here is that the price of the first symbol will decrease, or the price of the second will increase, or both, bringing the relationship back to its historical average.
Convergence to the Mean: As mentioned earlier, when the green line aligns closely with the purple line, it's an indication that the assets have returned to their typical price relationship. This serves as a signal for traders to consider closing out their positions, locking in the gains from the arbitrage opportunity.
It's important to note that when you're trading based on symbol relations, you're essentially betting on the relative performance of the two assets. This strategy, often referred to as "pairs trading," seeks to capitalize on price imbalances between related financial instruments. By taking opposing positions in the two symbols, traders aim to profit from the eventual reversion of the price difference to the mean.
Double Supertrend HTF FilterDouble Supertrend HTF Filter: A Comprehensive Market Direction Tool
The Double Supertrend HTF Filter is an innovative tool designed for traders who seek a more holistic view of market trends. At its core, the indicator combines two Supertrends from different higher timeframes, providing a layered perspective on the market's direction. Instead of juggling between multiple timeframes or charts, traders get a consolidated view with this indicator. One of its standout features is the horizontal line at the bottom of the chart, which visually represents the alignment of the two Supertrends – a simple yet powerful way to gauge the combined sentiment of the two higher timeframes on your chart.
The Supertrend Indicator: Origins and Rationale
The Supertrend indicator, a popular tool among traders, was developed by Olivier Seban. At its essence, the Supertrend is a trend-following indicator, designed to identify and visualize the current market trend. It operates using average true range (ATR) values and price data, effectively smoothing out market noise to present clearer trend directions. When prices move with a consistent momentum upwards or downwards, the Supertrend remains below or above the price respectively, signaling the prevailing trend's direction. The rationale behind the Supertrend is its ability to adapt to price volatility. By factoring in the average true range, it dynamically adjusts itself, ensuring that it's not just based on price but also the inherent volatility of the market. This adaptability makes it a valuable tool for traders, offering insights into potential trend reversals and potential entry or exit points.
Filter Usage
The main idea behind the Double Supertrend HTF is to use the indicator as a filter in addition to a signal indicator to your liking. To illustrate, consider incorporating it with a MACD Oscillator, such as the one detailed in this article: When the solid line at the bottom of the chart turns green, it signals that both supertrends are up and thus allows for long positions, indicating a bullish sentiment across both the chosen higher timeframes. Conversely, a red line permits short positions, hinting at a bearish trend. Should the line turn yellow, it's a sign of caution. The market is indecisive, and it might be prudent to refrain from taking any trades until a clearer direction emerges.
Features of the Indicator
Understanding that traders have different preferences, the Double Supertrend HTF Filter comes with customizable features. With the easy user interface you can change the timeframe, ATR and factor to your preferred trading strategy. The default settings are set for the 30 minutes and 4 hour timeframe, which is my personal preference for scalping trades on lower timeframes (eg. 1min, 5 min, 10 min, 15 min). While the dual Supertrend lines offer valuable insights, a chart can become cluttered when combined with other indicators. Therefore, traders have the option to toggle on or off the display of the Supertrends. This ensures that you have the flexibility to maintain a clean chart view while still benefiting from the insights the tool provides at the bottom of the chart.
A Note on Usage
It's essential to highlight that the Double Supertrend HTF Filter is for educational purposes. While it offers a unique perspective on market trends and can be a valuable addition to a trader's toolkit, it's merely an example of how one can use the Supertrend as a filter. Always conduct thorough research and consider your trading strategy before making any decisions.
If you have any comments or ideas how to combine this filter with other indicators feel free to leave a comment.
Expansion/Contraction Indicator (ECI) [Angel Algo]INTRODUCTION
The Expansion/Contraction Indicator (ECI) is a custom indicator designed to measure the expansion or contraction of price ranges between the open and close of each bar. It helps traders identify periods of increased or decreased volatility in the market. Since trading is most fruitful during volatile market conditions, this indicator provides valuable insights into when volatility increases, signaling the opportune moments to take action.
HOW TO USE
Expansion: When the ECI value is in the green zone, it suggests an expansion in price ranges, indicating increased volatility. This may be a potential signal for traders to expect trend movements or breakouts.
Contraction: When the ECI value falls outside the green zone, it indicates a contraction in price ranges, implying reduced volatility. This may signal potential consolidation or ranging periods in the market.
During contraction periods, it is advisable to exercise patience and await clear signals. Market cycles dictate that low-volatility contractions are often followed by high-volatility expansion periods, presenting opportunities for significant price movements.
Visualization:
Expansion Area: the area on the indicator chart filled with green. It has duller and brighter parts that indicate the level of expansion. The duller part corresponds to a low or beginning expansion.
ECI Dots: The ECI dots are plotted as circles on the chart. The dots are colored green if the ECI value is above the lower threshold, indicating an expansion. If the ECI value is below the lower threshold, the dots are colored red to indicate a contraction.
Alerts (Optional): The ECI indicator can generate alerts for expansions and contractions. By default, alerts are enabled. An expansion alert is triggered when the ECI value crosses above the upper threshold. A contraction alert is triggered when the ECI value crosses below the lower threshold.
SETTINGS
Period: determines the number of bars used to calculate the exponential moving average (EMA) of the price range. The default value is 14, but it can be set between 1 and 200. Higher values smooth out the indicator but may delay signals.
Lower Threshold: defines the level below which the ECI value indicates a contraction in price ranges, implying reduced volatility. The default value is 0.5.
CALCULATION
The indicator calculates the range between the open and close of each bar (ocRange). It then calculates the EMA of the range (emaRange) using the specified period. The ECI value is obtained by dividing the ocRange by the emaRange. Threshold Levels: The indicator includes two threshold levels for identifying expansions and contractions: a. Upper Threshold: Default value is 3.0. b. Lower Threshold: Default value is 0.5. The middle line (mL) represents the ECI value of 1.0, which indicates a neutral state, when the volatility in the market corresponds to its average value.
Rectified BB% for option tradingThis indicator shows the bollinger bands against the price all expressed in percentage of the mean BB value. With one sight you can see the amplitude of BB and the variation of the price, evaluate a reenter of the price in the BB.
The relative price is visualized as a candle with open/high/low/close value exspressed as percentage deviation from the BB mean
The indicator include a modified RSI, remapped from 0/100 to -100/100.
You can choose the BB parameters (length, standard deviation multiplier) and the RSI parameter (length, overbougth threshold, ovrsold threshold)
You can exclude/include the candles and the RSI line.
The indicator can be used to sell options when the volatility is high (the bollinger band is wide) and the price is reentering inside the bands.
If the price is forming a supply or demand area it can be a good opportunity to sell a bull put or a bear call
The RSI can be used as confirm of the supply/demand formation
If the bollinger band is narrow and the RSI is overbought/oversold it indicate a better opportunity to buy options
the indicator is designed to work with daily timeframe and default parameters.
Parabolic SAR ZoneThe Parabolic SAR Zone indicator is a tool designed to help traders identify the best zone to enter in a position revisiting the usage of the standard Parabolic SAR indicator.
In the settings you can choose all the parameters of the standard indicator, and in addition to that you can also change the multiplier for the zone width.
This indicator provides two different Parabolic SAR indicators, the first one has the settings that you chose and displays the zone, meanwhile, the second one has half the parameters you have chosen and can be used to determine the long-term trend direction.
Pro Supertrend CalculatorThis indicator is an adapted version of Julien_Eche's 'Pro Momentum Calculator' tailored specifically for TradingView's 'Supertrend indicator'.
The "Pro Supertrend Calculator" indicator has been developed to provide traders with a data-driven perspective on price movements in financial markets. Its primary objective is to analyze historical price data and make probabilistic predictions about the future direction of price movements, specifically in terms of whether the next candlestick will be bullish (green) or bearish (red). Here's a deeper technical insight into how it accomplishes this task:
1. Supertrend Computation:
The indicator initiates by computing the Supertrend indicator, a sophisticated technical analysis tool. This calculation involves two essential parameters:
- ATR Length (Average True Range Length): This parameter determines the sensitivity of the Supertrend to price fluctuations.
- Factor: This multiplier plays a pivotal role in establishing the distance between the Supertrend line and prevailing market prices. A higher factor value results in a more significant separation.
2. Supertrend Visualization:
The Supertrend values derived from the calculation are meticulously plotted on the price chart, manifesting as two distinct lines:
- Green Line: This line represents the Supertrend when it indicates a bullish trend, signifying an anticipation of rising prices.
- Red Line: This line signifies the Supertrend in bearish market conditions, indicating an expectation of falling prices.
3. Consecutive Candle Analysis:
- The core function of the indicator revolves around tracking successive candlestick patterns concerning their relationship with the Supertrend line.
- To be included in the analysis, a candlestick must consistently close either above (green candles) or below (red candles) the Supertrend line for multiple consecutive periods.
4.Labeling and Enumeration:
- To communicate the count of consecutive candles displaying uniform trend behavior, the indicator meticulously applies labels to the price chart.
- The positioning of these labels varies based on the direction of the trend, residing either below (for bullish patterns) or above (for bearish patterns) the candlestick.
- The color scheme employed aligns with the color of the candle, using green labels for bullish candles and red labels for bearish ones.
5. Tabular Data Presentation:
- The indicator augments its graphical analysis with a customizable table prominently displayed on the chart. This table delivers comprehensive statistical insights.
- The tabular data comprises the following key elements for each consecutive period:
a. Consecutive Candles: A tally of the number of consecutive candles displaying identical trend characteristics.
b. Candles Above Supertrend: A count of candles that remained above the Supertrend during the sequential period.
3. Candles Below Supertrend: A count of candles that remained below the Supertrend during the sequential period.
4. Upcoming Green Candle: An estimation of the probability that the next candlestick will be bullish, grounded in historical data.
5. Upcoming Red Candle: An estimation of the probability that the next candlestick will be bearish, based on historical data.
6. Tailored Configuration:
To accommodate diverse trading strategies and preferences, the indicator offers extensive customization options. Traders can fine-tune parameters such as ATR length, factor, label and table placement, and table size to align with their unique trading approaches.
In summation, the "Pro Supertrend Calculator" indicator is an intricately designed tool that leverages the Supertrend indicator in conjunction with historical price data to furnish traders with an informed outlook on potential future price dynamics, with a particular emphasis on the likelihood of specific bullish or bearish candlestick patterns stemming from consecutive price behavior.
L&S Volatility Index Refurbished█ Introduction
This is my second version of the L&S Volatility Index, hence the name "Refurbished".
The first version can be found at this link:
The reason I released a separate version is because I rewrote the source code from scratch with the aim of both improving the indicator and staying as close as possible to the original concept.
I feel that the first version was somewhat exotic and polluted in relation to the indicator originally described by the authors.
In short, the main idea remains the same, however, the way of presenting the result has been changed, reiterating what was said.
█ CONCEPTS
The L&S Volatility Index measures the volatility of price in relation to a moving average.
The indicator was originally described by Brazilian traders Alexandre Wolwacz (Stormer) and Fábio Figueiredo (Vlad) from L&S Educação Financeira.
Basically, this indicator can be used in two ways:
1. In a mean reversion strategy, when there is an unusual distance from it;
2. In a trend following strategy, when the price is in an acceptable region.
As an indicator of volatility, the greatest utility is shown in first case.
This is because it allows identifying abnormal prices, extremely stretched in relation to an average, including market crashes.
How the calculation is done:
First, the distance of the price from a given average in percentage terms is measured.
Then, the historical average volatility is obtained.
Finally the indicator is calculated through the ratio between the distance and the historical volatility.
According to the description proposed by the creators, when the L&S Volatility Index is above 30 it means that the price is "stretched".
The closer to 100 the more stretched.
When it reaches 0, it means the price is on average.
█ What to look for
Basically, you should look at non-standard prices.
How to identify it?
When the oscillator is outside the Dynamic Zone and/or the Fixed Zone (above 30), it is because the price is stretched.
Nothing on the market is guaranteed.
As with the RSI, it is not because the RSI is overbought or oversold that the price will necessarily go down or up.
It is critical to know when NOT to buy, NOT to sell or NOT to do anything.
It is always important to consider the context.
█ Improvements
The following improvements have been implemented.
It should be noted that these improvements can be disabled, thus using the indicator in the "purest" version, the same as the one conceived by the creators.
Resources:
1. Customization of limits and zones:
2. Customization of the timeframe, which can be different from the current one.
3. Repaint option (prints the indicator in real time even if the bar has not yet closed. This produces more signals).
4. Customization of price inputs. This affects the calculation.
5. Customization of the reference moving average (the moving average used to calculate the price distance).
6. Customization of the historical volatility calculation strategy.
- Accumulated ATR: calculates the historical volatility based on the accumulated ATR.
- Returns: calculates the historical volatility based on the returns of the source.
Both forms of volatility calculation have their specific utilities and applications.
Therefore, it is worthwhile to have both approaches available, and one should not necessarily replace the other.
Each method has its advantages and may be more appropriate in different contexts.
The first approach, using the accumulated ATR, can be useful when you want to take into account the implied volatility of prices over time,
reflecting broader price movements and higher impact events. It can be especially relevant in scenarios where unexpected events can drastically affect prices.
The second approach, using the standard deviation of returns, is more common and traditionally used to measure historical volatility.
It considers the variability of prices relative to their average, providing a more general measure of market volatility.
Therefore, both forms of calculation have their merits and can be useful depending on the context and specific analysis needs.
Having both options available gives users flexibility in choosing the most appropriate volatility measure for the situation at hand.
* When choosing "Accumulated ATR", if the indicator becomes difficult to see, there are 3 possibilities:
a) manually adjust the Fixed Zone value;
b) disable the Fixed Zone and use only the Dynamic Zone;
c) normalize the indicator.
7. Signal line (a moving average of the oscillator).
8. Option to normalize the indicator or not.
9. Colors to facilitate direction interpretation.
Since the L&S is a volatility indicator, it does not show whether the price is rising or falling.
This can sometimes confuse the user.
That said, the idea here is to show certain colors where the price is relative to the average, making it easier to analyze.
10. Alert messages for automations.
Guassian Distribution Forecast [prediction intervals]The Indicator
The Indicator combines volatility and frequency distributions to forecast an area of possible price expansion with an approximate confidence interval / level and level of significance (significance level).
The Script Formula
Additional comments
To alter the models forecasting precision to reflect a given confidence interval, e.g the 90% confidence level (C.L.), use the 1.64 multiplier (toggle value in "Standard normal distribution sd" setting), to use a specific C.L., e.g. the 85th percentile either search for this on google, or calculate it yourself using a Standard Normal Distribution Probability table. Additionaly volatility may be changed by toggling the lookback period setting, this can be thought of as widening the distribution tails.
The look forward parameter is currently fixed at 20, this is because it does not currently work correctly with higher integers, I will try resolve this problem and any other bugs as soon as possible
Value At RiskThe Value at Risk Channel (VaR Channel) is a trading indicator designed to assist traders in managing their risk exposure effectively. By allowing users to select a specific time period and a probability value, this indicator generates upper and lower limits that the price might potentially attain within the chosen timeframe and probability range.
CONCEPTS
This indicator employs the concept of Value at Risk (VaR) calculation, a crucial metric in risk management. VaR quantifies the potential financial loss within a position, portfolio, or company over a defined time period. Financial institutions like banks and investment firms use VaR to estimate the extent and likelihood of potential losses in their portfolios.
The "historical method" is utilized to compute VaR within the indicator. This method analyzes the historical performance of returns and constructs a histogram representing the statistical distribution of past returns. Assuming returns adhere to a normal distribution, probabilities are assigned to different return values based on their position in the distribution percentile.
HOW TO USE
Suppose you wish to plot upper and lower price limits for a 4-hour period with a 5% probability. Access the indicator's Settings tab and set the Timeframe parameter to "4 hours" while configuring the Probability parameter to 5.0.
The indicator serves as a tool to determine appropriate Stop-Loss levels triggering with low probability. Additionally, it helps gauge the likelihood of triggering such levels.
Likewise, you can assess the probability of your desired Take-Profit level being reached within a specified time frame. For instance, if you anticipate your target to be achieved within a week, set the Timeframe parameter to "1 week" and adjust the Probability parameter to align the VaR channel's limits with your Take-Profit level. The resulting Probability parameter value reflects the likelihood of your target being met within the expected time frame.
This indicator proves valuable for evaluating and managing risk, as well as refining trading strategies. If you discover other applications for this indicator, feel free to share them in the comments!
SETTINGS
Timeframe: Designates the time period within which the price might touch the VaR channel's upper or lower boundary, considering the specified Probability parameter.
Probability: Defines the likelihood of the price reaching the VaR channel's upper or lower limit during the timeframe determined by the Timeframe parameter.
Window: Establishes the historical period (number of past bars) utilized for VaR calculation.
[OKX Signal Bot] Indicator Script Set Up TemplateDiscover the power of the Turtle Trade Channels Indicator (TUTCI), an innovative tool that integrates the time-tested principles of the legendary Turtle Trade system. This groundbreaking system shattered the belief that successful traders are born, not made, by transforming ordinary individuals into profitable traders.
The Turtle Trade Experiment, which achieved a remarkable 80% annual return over four years and amassed a staggering $150 million, showcased the immense potential of this trend-following strategy. Unlike the conventional "buy low and sell high" approach, the Turtle Trade system embraces a different philosophy—one of capturing substantial profits by following prevailing trends.
At the heart of the Turtle Trade Channels Indicator lies the concept of Donchian Channels, a powerful technical indicator developed by Richard Donchian. Building upon this foundation, the main rule of TUTCI is to identify 20-day breakouts and capitalize on them, while simultaneously utilizing a profit-taking strategy based on breaching 10-day highs or lows.
For long trades, the indicator signals a buying opportunity when the price breaks above the 20-day high. Conversely, for short trades, a selling opportunity arises when the price falls below the 20-day low. This systematic approach allows traders to align themselves with the prevailing momentum, capturing significant price movements.
To further enhance trading precision, TUTCI incorporates two key lines. The red line represents the trading line, indicating the direction of the trend. Price bars above the trend line suggest an uptrend, while those below indicate a downtrend. The dotted blue line serves as the exit line, guiding traders to close their positions when price action breaches the 10-day high or low. This rule safeguards profits and helps traders avoid potential trend reversals.
The Turtle Trade Channels Indicator (TUTCI) is a versatile tool applicable to various financial markets, including stocks, commodities, and forex. By harnessing the power of breakouts and integrating profit-taking rules, this indicator empowers traders to capitalize on favorable trading opportunities while managing risk effectively.
As with any trading strategy, it is crucial to conduct thorough backtesting and evaluation of the TUTCI system before implementing it in live trading. Traders can customize the indicator's parameters to align with their trading preferences and adapt to changing market conditions. Employing sound risk management techniques, such as position sizing and stop-loss orders, is paramount to protect capital and minimize potential losses.
Experience the transformational potential of the Turtle Trade Channels Indicator (TUTCI) and embark on a journey of trend following, capturing significant profits, and achieving trading success.
These scripts are only functioning as sample script templates to support okx alert standards. It is not intended to provide any investment, tax, or legal advice, nor should it be considered an offer to purchase, sell, hold or offer any services relating to digital assets. Digital assets, including stablecoins, involve a high degree of risk, can fluctuate greatly, and can even become worthless. You should carefully consider whether trading or holding digital assets is suitable for you in light of your financial condition and risk tolerance. OKX does not provide investment or asset recommendations. You are solely responsible for your investment decisions, and OKX is not responsible for any potential losses. Past performance is not indicative of future results. Please consult your legal/tax/investment professional for questions about your specific circumstances.
Trend Confirmation StrategyThe profitability and uniqueness of a trading strategy depend on various factors including market conditions, risk management, and the strategy's ability to capitalize on price movements. I'll describe the strategy provided and highlight its potential benefits and differences compared to other strategies:
Strategy Overview:
The provided strategy combines three technical indicators: Supertrend, MACD, and VWAP. It aims to identify potential entry and exit points by confirming trend direction and considering the proximity to the VWAP level. The strategy also incorporates stop-loss and take-profit mechanisms, as well as a trailing stop.
Unique Aspects and Potential Benefits:
Trend Confirmation: The strategy uses both Supertrend and MACD to confirm the trend direction. This dual confirmation can increase the likelihood of accurate trend identification and filter out false signals.
VWAP Confirmation: The strategy considers the proximity of the price to the VWAP level. This dynamic level can act as a support or resistance and provide additional context for entry decisions.
Adaptive Stop Loss: The strategy sets a stop-loss range, which helps provide some tolerance for minor price fluctuations. This adaptive approach considers market volatility and helps prevent premature stop-loss triggers.
Trailing Stop: The strategy incorporates a trailing stop mechanism to lock in profits as the trade moves in the desired direction. This can potentially enhance profitability during strong trends.
Partial Profit Booking: While not explicitly implemented in the provided code, you could consider booking partial profits when the MACD shows a crossover in the opposite direction. This aspect could help secure gains while still keeping exposure to potential further price movements.
Key Differences from Other Strategies:
Dual Indicator Confirmation: The combination of Supertrend and MACD for trend confirmation is a unique aspect of this strategy. It adds an extra layer of filtering to enhance the accuracy of entry signals.
Dynamic VWAP: Incorporating the VWAP level into the decision-making process adds a dynamic element to the strategy. VWAP is often used by institutional traders, and its inclusion can provide insights into the market sentiment.
Adaptive Stop Loss and Trailing: The strategy's use of an adaptive stop-loss range and a trailing stop can help manage risk and protect profits more effectively during changing market conditions.
Partial Profit Booking: The suggestion to consider partial profit booking upon MACD crossovers in the opposite direction is a practical approach to secure gains while staying in the trade.
Caution and Considerations:
Backtesting: Before deploying any strategy in real trading, it's crucial to thoroughly backtest it on historical data to understand its performance under various market conditions.
Risk Management: While the strategy has built-in risk management mechanisms, it's essential to carefully manage position sizes and overall portfolio risk.
Market Conditions: No strategy works well in all market conditions. It's important to be flexible and adjust the strategy or refrain from trading during particularly volatile or unpredictable periods.
Continuous Monitoring: Even though the strategy includes automated components, continuous monitoring of the trades and market conditions is necessary.
Adaptability: Markets can change over time. Traders need to be prepared to adapt the strategy as necessary to stay aligned with evolving market dynamics.
Bollinger Band Percentile SuiteThe Bollinger Band Percentile Suite (𝐵𝐵𝒫𝒸𝓉 𝒮𝓊𝒾𝓉𝑒) is a comprehensive and customizable toolkit built upon the foundation of the %B indicator. The methodology behind this toolkit remains consistent with the original %B indicator, while introducing a host of powerful features to enhance its functionality and adaptability.
Key Features and Customization:
The 𝐵𝐵𝒫𝒸𝓉 offers a wide array of customizable options to suit your trading preferences and strategies. It includes a variety of 14 moving average types that can be chosen as the basis for the Bollinger Band calculation. Additionally, traders have the flexibility to set their upper and lower boundaries for mean reversion detection, allowing for analysis tailored to the user's preference.
Deviation Calculation:
The toolkit provides an option to choose between standard and weighted deviation calculation methods. This added customization ensures that the indicator's behavior aligns with your unique trading style and preferences.
Signals and Reversals:
The 𝐵𝐵𝒫𝒸𝓉 excels in identifying potential overbought and oversold market conditions. It highlights these levels on the chart and marks potential reversal signals with small circles positioned either at the top or bottom of the indicator pane, providing traders with actionable insights.
Trend and Color Coding:
Incorporating a color-coded approach, the BBpct Suite enhances your understanding of market dynamics. It offers bar coloring options based on trend, allowing traders to identify bullish or bearish market conditions as the percentile goes above or below the midline.
Extremities and Reversions:
Recognizing extreme market conditions is crucial for traders. The 𝐵𝐵𝒫𝒸𝓉 includes color-coded indicators for extremities, indicating when the percentile ventures above or below the predefined thresholds. Moreover, it promptly identifies reversions by marking the moment the percentile crosses under the upper threshold (overbought) or over the lower threshold (oversold).
The Bollinger Band Percentile Suite equips traders with a versatile toolkit to gain valuable insights into market overbought and oversold conditions, and potential reversal signals. Its extensive customization options and array of features empower traders to make well-informed decisions based on their unique trading strategies and risk tolerance.
Please note that while the BBpct Suite provides robust analysis, it is advisable to combine its insights with other technical indicators and tools for a comprehensive trading approach.
Example Chart:
Greedy DCA█ OVERVIEW
Detect price crashes in volatile conditions. This is an indicator for a greedy dollar cost average (DCA) strategy. That is, for people who want to repeatedly buy an asset over time when its price is crashing.
█ CONCEPTS
Price crashes are indicated if the price falls below one or more of the 4 lower Bollinger Bands which are calculated with increasing multipliers for the standard deviation.
In these conditions, the price is far below the average. Therefore they are considered good buying opportunities.
No buy signals are emitted if the Bollinger Bands are tight, i.e. if the bandwidth (upper -lower band) is below the value of the moving average multiplied with a threshold factor. This ensures that signals are only emitted if the conditions are highly volatile.
The Bollinger Bands are calculated based on the daily candles, irrespective the chart time frame. This allows to check the strategy on lower time frames
Floor and Roof IndicatorThe Floor and Roof indicator is a tool developed to help traders identify potential areas of support and resistance both for trend following and for mean reversal trading decisions.
The indicator plots the "Roof" which is the main level of resistance, and the "Floor" which is the main level of support. These lines are calculated on the "Lenght" parameter and smoothed by the "Smooth" parameter, and they use both the volatility and the main market structure as calculation methods.
Additionally, this indicator plots an area that can be modified by the "Zone width" parameter and two other lines, called "Second floor" and "Second roof" respectively, which are plotted only whenever they are significant to the price current level.
This indicator can be used in several ways:
- In a clear trend, you could wait for a break of the second floor or roof as an indication of a change in the market direction
- As the price goes out of the reversal zones, this can be an indication of a reversal
- In a clear trend, you can wait for the price to bounce on the second floor or roof lines to enter a trade
Buying Selling Volume StrategyFirst I would like to give the original credit and thanks to @ceyhun for his amazing volume script.
The way I decided to convert it into a strategy is divided into multiple types.
First, I decided in order to smooth out the values and make it more accurate to adapt the values to multiple timeframes.
After that I took the initial values from the buyers and sellers , and made a rest operation between them to have a flat difference between the power of both sides.
WIth that later on I decided to to apply a volatility filter,in this case bollinger bands, in order to find out potential leading trends.
At the same time in order to filter even more, I decided to make use as well for weekly VWAP values of the asset used.
Lastly I added a dynamic risk management into it , based on the ATR Daily values of the asset values.
As for the rules used, for example for long, I am looking that the price of the asset is above the weekly VWAP, after that I am checking that the MTF volume rest operation is both bullish and above the upper side of the bollinger.
For short we would want the asset to be below the weekly VWAP, and the volume to be bearish and above the upper side of bollinger.
The exit is either based on daily ATR values multipliers, or if we have a reverse condition.
If you have any questions, please let me know !
CPR (Central Pivot Range)Central Pivot Range is a trend and volatility forecasting tool. It is calculated from previous session's (day, week, or month) high, low, close values. It works on the idea that every trading session must be the result of its previous trading session.
Pivot, top pivot and bottom pivot values form the CPR. If the CPR for each trading session is getting higher (and also the price is trading above it) then it denotes bullish bias and vice versa for bearish. And the width of the CPR (i.e., distance between top and bottom pivot) denotes the volatility of the session.
If the CPR width is narrow, we can expect a trending or volatile trading session. If it's wide, then we can expect a range bound or sideways trading session.
Support and Resistance levels can be used as a profit booking zone or to add/reduce position sizing.
In this Indicator you have the following:
1. CPR with traditional support and resistance levels (S1-S5 & R1-R5).
2. Developing CPR for next trading day, week, and month.
3. Customizable lookback period, line width.
4. Option to show/hide labels, prices, SR levels, developing CPR.