Ehlers Combo Strategy🚀 Presenting the Enhanced Ehlers Combo Strategy 🚀
Hello Traders! 👋 I'm thrilled to share the latest version of the Ehlers Combo Strategy v2.0. This powerful algorithm combines Ehlers Elegant Oscillator, Decycler, Instantaneous Trendline, Spearman Rank, and introduces the Signal to Noise Ratio for even more precise trading signals.
📊 Strategy Highlights:
Ehlers Elegant Oscillator: Captures market momentum and turning points.
Ehlers Decycler: Filters out market noise for clearer trend signals.
Instantaneous Trendline: Offers a dynamic view of the market trend.
Spearman Rank: Analyzes market rank correlations for enhanced insights.
Signal to Noise Ratio (SNR): Filters out noise for more accurate signals.
💡 Key Features & Customizations:
Adaptive Length: Enable adaptive length based on the market's current conditions.
SNR Threshold: Set your desired SNR threshold for filtering signals.
Exit Length: Define the length for exit signals.
📈 Trading Signals:
Long Entry: Elegant Oscillator and Decycler cross above 0, source crosses above Decycler, source is greater than an increasing Instantaneous Trendline, Spearman Rank is positive, and SNR exceeds the threshold.
Long Exit: Source crosses below the Instantaneous Trendline after entering a long position.
Short Entry: Elegant Oscillator and Decycler cross below 0, source crosses below Decycler, source is less than a decreasing Instantaneous Trendline, Spearman Rank is negative, and SNR exceeds the threshold.
Short Exit: Source crosses above the Instantaneous Trendline after entering a short position.
📊 Insights & Enhancements:
Dynamic Length: The strategy adapts its length dynamically based on market conditions.
Improved SNR: Signal to Noise Ratio ensures better filtering of signals.
Enhanced Visualization: The Elegant Oscillator now features improved color coding for a clearer interpretation.
🚨 Disclaimer:
Trading involves risk, and this script should be used judiciously. It's not a guaranteed profit machine, but with careful use, it can be a valuable addition to your toolkit.
Feel free to backtest, tweak, and make it your own! Let's conquer the markets together! 💪📈
🚀✨ Happy Trading! ✨🚀
---
🙌 Credits:
A big shoutout to the original contributors:
@blackcat1402
@cheatcountry
@DasanC
Buysellsignal
Logical Trading Indicator V.1Features of the Logical Trading Indicator V.1
ATR-Based Trailing Stop Loss
The Logical Trading Indicator V.1 utilizes the Average True Range (ATR) to implement a dynamic trailing stop loss. You can customize the sensitivity of your alerts by adjusting the ATR Multiple and ATR Period settings.
Higher ATR Multiple values create wider stops, while lower values result in tighter stops. This feature ensures that your trades are protected against adverse price movements. For best practice, use higher values on higher timeframes and lower values on lower term timeframes.
Bollinger Bands
The Logical Trading Indicator V.1 includes Bollinger Bands, which can be customized to use either a Simple Moving Average (SMA) or an Exponential Moving Average (EMA) as the basis.
You can adjust the length and standard deviation multiplier of the Bollinger Bands to fine-tune your strategy. The color of the basis line changes to green when price is above and red when price is below the line to represent the trend.
The bands show a range vs a single band that also represents when the price is in overbought and oversold ranges similar to an RSI. These bands also control the take profit signals.
You also have the ability to change the band colors as well as toggle them off, which only affects the view, they are still active which will still fire the take profit signals.
Momentum Indicator
Our indicator offers a momentum filter option that highlights market momentum directly on the candlesticks, identifying periods of bullish, bearish, or consolidation phases. You can enable or disable this filter as needed, providing valuable insights into market conditions.
By default, you will see the candlestick colors represent the momentum direction as green or red, and consolidation periods as white, but the filter on the BUY and SELL signals is not active. The view options and filter can be toggled on and off in the settings.
Buy and Sell Signals
The Logical Trading Indicator V.1 generates buy and sell signals based on a combination of ATR-based filtering, Bollinger Band basis crossover, and optional momentum conditions if selected in the settings. These signals help you make informed decisions about when to enter or exit a trade. You can also enable a consolidation filter to stay out of trades during tight ranges.
Basically a BUY signal fires when the price closes above the basis line, and the price meets or exceeds the ATR multiple from the previous candle length, which is also editable in the settings.
If the momentum filter is engaged, it will not fire BUY signals when in consolidation periods. It works just the opposite for SELL signals.
Take Profit Signals
We've integrated a Take Profit feature that helps you identify points to exit your trades with profits. The indicator marks Long Take Profit when prices close below the upper zone line of the Bollinger Bands after the previous candle closes inside the band, suggesting an optimal point to exit a long trade or consider a short position.
Conversely, Short Take Profit signals appear when prices close above the lower zone after the previous candle closes inside of it, indicating the right time to exit a short trade or contemplate a long position.
Alerts for Informed Trading
The Logical Trading Indicator V.1 comes equipped with alert conditions for buy signals, sell signals, take profit points, and more. Receive real-time notifications to your preferred devices or platforms to stay updated on market movements and trading opportunities.
buy/sell signals with Support/Resistance (InvestYourAsset) 📣The present indicator is a MACD based buy/sell signals indicator with support and resistance, that can be used to identify potential buy and sell signals in a security's price.
📣It is based on the MACD (Moving Average Convergence Divergence) indicator, which is a momentum indicator that shows the relationship between two moving averages of a security's price.
📣 The indicator also plots support and resistance levels, which can be used to confirm buy and sell signals. The support and resistance can also be used as a stoploss for existing position.
👉 To use the indicator, simply add it to your trading chart. The indicator will plot three sections:
📈 Price and Signals: This section plots the security's price and the MACD buy and sell signals.
📈 MACD Oscillator: This section plots the MACD oscillator, which is a histogram that shows the difference between the two moving averages.
📈 Moving Averages: This section plots the two moving averages that the MACD oscillator is based on.
📈 Support and Resistance: This section plots support and resistance levels, which are calculated based on the security's recent price action.
👉 To identify buy and sell signals, you can look for the following:
📈 Buy signal: When shorter Moving Average crosses over longer Moving Average.
📈 Sell signal: When shorter moving average crosses under longer moving average.
📈 You can also look for divergences between the MACD oscillator and the security's price. A divergence occurs when the MACD oscillator is moving in one direction, but the security's price is moving in the opposite direction. Divergences can be a sign of a potential trend reversal.
👉 To confirm buy and sell signals, you can look for support and resistance levels take a look at below snapshot. If a buy signal occurs at a support level, it is a stronger signal than if it occurs at a random price level. Similarly, if a sell signal occurs at a resistance level, it is a stronger signal than if it occurs at a random price level.
⚡ Here is a example of how to use the indicator to identify buy signal:
☑ Add the indicator to your trading chart.
☑Look for a buy signal when short MA crosses over Long MA.
☑Look for the buy signal to occur at a support level.
☑Enter a long position at the next candle.
☑Place a stop loss order below the support level.
☑Take profit when the MACD line crosses below the signal line, or when the security reaches a resistance level.
⚡ Here is an example of how to use the indicator to identify a sell signal:
☑Add the indicator to your trading chart.
☑Look for a sell signal, when shorter moving average crosses under longer moving average.
☑Look for the sell signal to occur at a resistance level.
☑Enter a short position at the next candle.
☑Place a stop loss order above the resistance level.
☑Take profit when the MACD line crosses above the signal line, or when the security reaches a support level.
✅Things to consider while using the indicator:
📈Look for buy signals in an uptrend and sell signals in a downtrend. This will increase the likelihood of your trades being successful.
📈Place your stop losses below the previous swing low or support for buy signals and above the previous swing high or resistance for sell signals. This will help to limit your losses if the trade goes against you.
📈Consider taking profits at key resistance and support levels. This will help you to lock in your profits and avoid giving them back to the market.
Follow us for timely updates regarding indicators that we may publish in future and give it a like if you appreciate the indicator.
Breakout/Breakdown Indicator (30 Min Range) by InvestYourAsset👉The indicator provided here is a technical analysis indicator for TradingView users that identifies potential breakout and breakdown opportunities on the initial 30-minute range in every trading session.
👉The indicator high and low of the initial 30-minute period and plotting them as horizontal lines on the chart. The high is marked in green line and the low is marked in red line.
📈The indicator then generates buy and sell signals based on whether the current close price crosses above or below the previous 30-minute high and low, respectively.
📢The indicator also has two inputs:
👉 sessionStartHour : The hour at which the trading session begins. The default value is 9, However users can change the time according to their own trading style.
👉 sessionStartMinute : The minute at which the trading session begins. The default value is 0.
These inputs can be used to adjust the indicator to the specific trading session that you are interested in.
✅How to use the Indicator:
👉To use the 30 Minute Breakout/Breakdown Indicator, simply add it to your chart and configure the inputs to your liking. Once the indicator is added to the chart, it will plot the 30-minute high and low as horizontal lines, as well as generate buy and sell signals based on the current close price.
✅Here is a step-by-step guide:
📈Open TradingView and select the chart that you want to add the indicator to.
📈Click on the "Indicators" tab and search for "30 Minute Breakout/Breakdown Indicator by InvestYourAsset".
📈Click on the indicator to add it to your chart.
📈Configure the inputs to your liking. The default values are typically fine, but you can experiment with different values to see what works best for you.
📈Once you are satisfied with the settings, click on the "Apply" button.
📈The indicator will now be displayed on your chart. You will see two horizontal lines representing the previous 30-minute high and low, as well as triangles representing buy and sell signals.
✅How to interpret the signals:
📈Buy signal : A buy signal is generated when the current close price crosses above the previous 30-minute high. This suggests that the price is likely to continue moving higher in the short term.
📈Sell signal : A sell signal is generated when the current close price crosses below the previous 30-minute low. This suggests that the price is likely to continue moving lower in the short term.
👉Traders should remember that the present indicator is just one tool that can be used to identify potential trading opportunities. It is important to use other technical analysis tools and risk management techniques to confirm your trading signals before entering any trades.
✅Things to consider while using the indicator:
📈Look for buy signals in an uptrend and sell signals in a downtrend. This will increase the likelihood of your trades being successful.
📈Place your stop losses below the previous 30-minute low for buy signals and above the previous 30-minute high for sell signals. This will help to limit your losses if the trade goes against you.
📈Consider taking profits at key resistance and support levels. This will help you to lock in your profits and avoid giving them back to the market.
Follow us for timely updates regarding indicators that we may publish in future and give it a like if you appreciate the indicator.
VWAP with CharacterizationThis indicator is a visual representation of the VWAP (Volume Weighted Average Price), it calculates the weighted average price based on trading volume. Essentially, it provides a measure of the average price at which an asset has traded during a given period, but with a particular focus on trading volume. In our case, the indicator calculates the VWAP for the current trading symbol, using a predefined simple moving average (SMA) with a period of 14. This volume-weighted moving average offers a clearer view of the behavior of the VWAP and, of consequence of market dynamics.
One of the distinctive features of this indicator is its ability to provide a more "linear" representation of the data. This means that the data is "smoothed" to remove noise, allowing you to more easily identify the direction of the market trend. This smoother representation is especially useful because the financial market can be subject to significant fluctuations and volatility, and this indicator can help get a more stable view of the trend.
The indicator also offers a visualization of the market trend in a very intuitive way. Using an evaluation of the highs and lows of the last 10 days, determine whether the market is in an uptrend, downtrend, or no trend at all. To make this evaluation even clearer and more immediate, the indicator line is colored dynamically. When the trend is bullish, the line is blue, while in case of a bearish trend, it takes on a distinctive color, such as pink. If the trend is not defined, the line will be colored differently, for example light yellow. This coloration gives traders an immediate visual indication of the prevailing trend, allowing them to make more informed decisions regarding trading operations.
One potential strategy involves watching candles when they cross the VWAP line strongly. If, for example, a candlestick breaks above the VWAP line, we may look for retest areas near key support levels to gauge a potential long entry. In other words, we would consider that the price may have the potential to rise further after breaking above the VWAP line, and we would look to enter a long position to take advantage of this opportunity.
On the other hand, if a candlestick crosses below the VWAP line, we might consider looking for retest areas near the VWAP line itself, which now serves as potential resistance. This could indicate a possible short entry opportunity, as the price may struggle to break above the resistance represented by the VWAP line after breaking it down. In this case, we would look to take advantage of the expected continuation of the downtrend.
In both cases, the idea is to exploit significant movements across the VWAP line as signals of potential reversal or continuation of the trend. This strategy can help identify key entry points based on price behavior relative to the VWAP line.
DIY Custom Strategy Builder [ZP] - v1DISCLAIMER:
This indicator as my first ever Tradingview indicator, has been developed for my personal trading analysis, consolidating various powerful indicators that I frequently use. A number of the embedded indicators within this tool are the creations of esteemed Pine Script developers from the TradingView community. In recognition of their contributions, the names of these developers will be prominently displayed alongside the respective indicator names. My selection of these indicators is rooted in my own experience and reflects those that have proven most effective for me. Please note that the past performance of any trading system or methodology is not necessarily indicative of future results. Always conduct your own research and due diligence before using any indicator or tool.
===========================================================================
Introducing the ultimate all-in-one DIY strategy builder indicator, With over 30+ famous indicators (some with custom configuration/settings) indicators included, you now have the power to mix and match to create your own custom strategy for shorter time or longer time frames depending on your trading style. Say goodbye to cluttered charts and manual/visual confirmation of multiple indicators and hello to endless possibilities with this indicator.
What it does
==================
This indicator basically help users to do 2 things:
1) Strategy Builder
With more than 30 indicators available, you can select any combination you prefer and the indicator will generate buy and sell signals accordingly. Alternative to the time-consuming process of manually confirming signals from multiple indicators! This indicator streamlines the process by automatically printing buy and sell signals based on your chosen combination of indicators. No more staring at the screen for hours on end, simply set up alerts and let the indicator do the work for you.
Available indicators that you can choose to build your strategy, are coded to seamlessly print the BUY and SELL signal upon confirmation of all selected indicators:
EMA Filter
2 EMA Cross
3 EMA Cross
Range Filter (Guikroth)
SuperTrend
Ichimoku Cloud
SuperIchi (LuxAlgo)
B-Xtrender (QuantTherapy)
Bull Bear Power Trend (Dreadblitz)
VWAP
BB Oscillator (Veryfid)
Trend Meter (Lij_MC)
Chandelier Exit (Everget)
CCI
Awesome Oscillator
DMI ( Adx )
Parabolic SAR
Waddah Attar Explosion (Shayankm)
Volatility Oscillator (Veryfid)
Damiani Volatility ( DV ) (RichardoSantos)
Stochastic
RSI
MACD
SSL Channel (ErwinBeckers)
Schaff Trend Cycle ( STC ) (LazyBear)
Chaikin Money Flow
Volume
Wolfpack Id (Darrellfischer1)
QQE Mod (Mihkhel00)
Hull Suite (Insilico)
Vortex Indicator
2) Overlay Indicators
Access the full potential of this indicator using the SWITCH BOARD section! Here, you have the ability to turn on and plot up to 14 of the included indicators on your chart. Simply select from the following options:
EMA
Support/Resistance (HeWhoMustNotBeNamed)
Supply/ Demand Zone ( SMC ) (Pmgjiv)
Parabolic SAR
Ichimoku Cloud
Superichi (LuxAlgo)
SuperTrend
Range Filter (Guikroth)
Average True Range (ATR)
VWAP
Schaff Trend Cycle ( STC ) (LazyBear)
PVSRA (TradersReality)
Liquidity Zone/Vector Candle Zone (TradersReality)
Market Sessions (Aurocks_AIF)
How it does it
==================
To explain how this indictor generate signal or does what it does, its best to put in points.
I have coded the strategy for each of the indicator, for some of the indicator you will see the option to choose strategy variation, these variants are either famous among the traders or its the ones I found more accurate based on my usage. By coding the strategy I will have the BUY and SELL signal generated by each indicator in the backend.
Next, the indicator will identify your selected LEADING INDICATOR and the CONFIRMATION INDICATOR(s).
On each candle close, the indicator will check if the selected LEADING INDICATOR generates signal (long or short).
Once the leading indicator generates the signal, then the indicator will scan each of the selected CONFIRMATION INDICATORS on candle close to check if any of the CONFIRMATION INDICATOR generated signal (long or short).
Until this point, all the process is happening in the backend, the indicator will print LONG or SHORT signal on the chart ONLY if LEADING INDICATOR and all the selected CONFIRMATION INDICATORS generates signal on candle close. example for long signal, the LEADING INDICATOR and all selected CONFIRMATION INDICATORS must print long signal.
The dashboard table will show your selected LEADING and CONFIRMATION INDICATORS and if LEADING or the CONFIRMATION INDICATORS have generated signal. Signal generated by LEADING and CONFIRMATION indicator whether long or short, is indicated by tick icon ✔. and if any of the selected CONFIRMATION or LEADING indicator does not generate signal on candle close, it will be indicated with cross symbol ✖.
how to use this indicator
==============================
Using the indicator is pretty simple, but it depends on your goal, whether you want to use it for overlaying the available indicators or using it to build your strategy or for both.
To use for Building your strategy: Select your LEADING INDICATOR, and then select your CONFIRMATION INDICATOR(s). if on candle close all the indicators generate signal, then this indicator will print SHORT or LONG signal on the chart for your entry. There are plenty of indicators you can use to build your strategy, some indicators are best for longer time frame setups while others are responsive indicators that are best for short time frame.
To use for overlaying the indicators: Open the setting of this indicator and scroll to the SWITCHBOARD section, from there you can select which indicator you want to plot on the chart.
For each of the listed indicators, you have the flexibility to customize the settings and configurations to suit your preferences. simply open indicator setting and scroll down, you will find configuration for each of the indicators used.
I will also release the Strategy Backtester for this indicator soon.
Buy/Sell BoxThis indicator tries to identify the points where the price exceeds or falls below a rectangle based on the opening and closing prices of the previous period, the creation of the boxes occurs when a doji is detected therefore it will calculate the coordinates of the rectangle that will be drawn around it, therefore the indicator offers buy or sell signals based on this logic. Specifically, the buy signal is generated if the closing price is above the top of the rectangle and satisfies some previous price conditions while the sell signal is generated if the closing price is below the bottom of the rectangle and satisfies some conditions of previous prices within a further threshold based on the Ema 150.
Lines are then drawn on the graph to visually display the extreme price levels, which can be useful for any confirmation of buy and sell signals, Stop Loss and Take Profit, Trend Filter (to visually understand if the trend is bullish or bearish)
A potentially effective trading strategy could involve identifying buy and sell signals near the extreme price level lines drawn by the indicator. This approach can be used to try to improve the accuracy of your trading signals and make more informed decisions. For example:
When you receive a buy or sell signal based on the dojis and rectangles generated by the indicator, check whether the price is also near one of the extreme price level lines. If you are receiving a buy signal and notice that the current price is near a low of the lower level line, this may further confirm the buying opportunity, as the price is near a significant resistance level. On the contrary, if the sell signal was close to a maximum price level it could confirm an excellent short entry.
It is also possible to use the boxes as reference points to set the stop loss and take profit levels. If you are entering a buy position, you might consider setting your stop loss just below an upper line of the last box. Additionally, you may want to set your take profit near a higher price level if you are looking to maximize profits. This will help manage risks and protect your capital.
RSRS (Resistance Support Relative Strength)The Resistance Support Relative Strength (RSRS) indicator, published by Everbright Securities, is a technical analysis tool that enjoys immense popularity among Chinese quantitative traders, owing to its stellar performance in China's stock markets.
🟠 Principle
The indicator treats daily highs and lows as resistance and support levels respectively. It measures market strength by comparing the magnitude of price changes in daily highs versus lows. Specifically, it fits a linear regression model to the (low, high) data points over the past N days (typically 18) and uses the slope (beta) as the RSRS value. A steeper slope indicates stronger market strength.
🟠 Algorithm
1. Collect the daily low and high prices over the past N days.
2. Apply Ordinary Least Squares to estimate the linear regression model: high = alpha + beta * low. The beta is the RSRS value.
3. Compute the z-score of the RSRS over the past M days (typically 600).
4. Compare the z-score to preset buy and sell thresholds (typically 0.7 and -0.7) to generate trading signals. If z-score > buy threshold, a buy signal is triggered. If z-score < sell threshold, a sell signal is triggered.
Buy/Sell EMA CrossoverThe indicator identifies potential trading opportunities within the market. It is entirely based on the combination of exponential moving averages by drawing triangles on the chart that identify buy or sell signals combined with vertical bars that create areas of interest.
Specifically, when a buy signal occurs, the indicator draws a vertical bar with an azure background, indicating a possible buy area. Similarly, a sell signal is represented by a vertical bar with a fuchsia background, indicating a possible sell area.
These areas represent the main point of the indicator which uses exponential moving averages which, based on the direction of prices, identify the trend and color the background of the graph in order to visually highlight the predominant trend.
The green triangles above the bars of the chart suggest possible upside opportunities (good bullish entry points) when the 21 ema crosses the 200 ema.
While on the contrary the red triangles, 21 ema lower than the 200 ema, can indicate possible bearish trends (good bearish entry points).
While the white and purple triangles reveal moments of potential indecision or market change.
We can think of them as situations of uncertain trend in which it is possible to place a long or short order near some conditions that we are going to see.
The white triangles below, which are created when the 13 ema is higher than the 21 ema, indicate a possible bullish zone while the purple triangles above (13 ema lower than the 21) could suggest a bearish reflex
Colored lines represent moving averages blue = 200, 21= fuchsia and 13 = white. If the price is above the 200 period line then it could be a bullish opportunity, otherwise it could be a bearish one.
An interesting strategy to adopt is to evaluate, for example, the inputs near the vertical bars (azure - long) (fuchsia - short) when a white or purple triangle appears.
The more prominent green triangle indicates that the trend is going in a long direction.
On the contrary, the red (short) triangles are the opposite of the green ones and have the same importance as input logic.
The white triangle instead present more often inside the indicator identifies interesting buying areas of short duration, it is important to consider that the closer the triangles are to the vertical blue bars the stronger the entry signal.
Finally, the purple triangles are the short-term bearish trends whose entry near the fuchsia vertical bars defines a short.
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.
Buy/Sell EMA CandleThis indicator is designed to display various technical indicators, candle patterns, and trend directions on a price chart. Let's break down the code and explain its different sections:
Exponential Moving Averages (EMA):
The code calculates and plots five EMAs of different lengths (13, 21, 55, 90, and 200) on the price chart. These EMAs are used to identify trends and potential crossovers.
Engulfing Candle Patterns:
The code identifies and highlights potential bullish and bearish engulfing candle patterns. It checks if the current candle's body size is larger than the combined body sizes of the previous and subsequent four candles. If this condition is met, it marks the pattern on the chart.
s3.tradingview.com
EMA Crossovers:
The code identifies and highlights points where the shorter EMA (ema1) crosses above or below the longer EMA (ema2). It plots circles to indicate these crossover points.
Candle Direction and RSI Trend:
The code determines the trend direction of the last candle based on whether it closed higher or lower than its open price. It also calculates the RSI (Relative Strength Index) and determines its trend direction (overbought, oversold, or neutral) based on predefined thresholds.
s3.tradingview.com
Table Display:
The code creates a table displaying trend directions for different timeframes (monthly, weekly, daily, 4-hour, and 1-hour) for candle direction and RSI trends. The trends are labeled with "L" for long, "S" for short, and "N/A" for not applicable.
High Volume Bars (HVB):
The code identifies and colors bars with above-average volume as either bullish or bearish based on whether the price closed higher or lower than it opened. The color and conditions for high volume bars can be customized.
s3.tradingview.com
Doji Candle Pattern:
The code identifies and marks doji candle patterns, where the open and close prices are very close to each other within a certain percentage of the candle's high-low range.
RSI-Based Candle Coloring:
The code adjusts the color of the candles based on the RSI value. If the RSI value is above the overbought threshold or below the oversold threshold, the candles are colored yellow.
Usage and Interpretation:
Traders can use this indicator to identify potential trend changes based on EMA crossovers and candle patterns like engulfing and doji.
The RSI trend direction can provide additional insight into potential overbought or oversold conditions.
High volume bars can indicate potential price reversals or continuation patterns.
The table provides an overview of trend directions on different timeframes for both candle direction and RSI trends.
Keep in mind that this is a complex indicator with multiple features. Users should carefully evaluate its performance and consider combining it with other indicators and analysis methods for more accurate trading decisions.
The table is designed to provide a consolidated view of trend directions and other indicators across multiple timeframes. It is displayed on the chart and organized into rows and columns. Each row corresponds to a specific aspect of analysis, and each column corresponds to a different timeframe.
Here's a breakdown of the components of the table:
Row 1: Separation.
Row 2 (Header Row): This row contains the headers for the columns. The headers represent the different timeframes being analyzed, such as Monthly (M), Weekly (W), Daily (D), 4-hour (4h), and 1-hour (1h).
Row 3 (Content Row): This row contains labels indicating the types of information being displayed in the columns. The labels include "T" for Trend, "C" for Current Candle, and "R" for RSI Trend.
Row 4 and Onwards: These rows display the actual data for each aspect of analysis across different timeframes.
For each aspect of analysis (Trend, Current Candle, RSI Trend), the corresponding rows display the following information:
Monthly (M): The trend direction for the given aspect on the monthly timeframe.
Weekly (W): The trend direction for the given aspect on the weekly timeframe.
Daily (D): The trend direction for the given aspect on the daily timeframe.
4-hour (4h): The trend direction for the given aspect on the 4-hour timeframe.
1-hour (1h): The trend direction for the given aspect on the 1-hour timeframe.
The trend directions are represented by labels such as "L" for Long, "S" for Short, or "N/A" for Not Applicable.
The table's purpose is to provide a quick overview of trend directions and related information across multiple timeframes, aiding traders in making informed decisions based on the analysis of trend changes and other indicators.
Extreme Entry with Mean Reversion and Trend FilterThis non-repainting indicator is an improved version of my previous work, a more versatile tool designed to provide traders with dynamic and adaptive entry signals while incorporating a mean reversion and trend filtering mechanism. By combining RSI overbought/oversold, regular divergence and confirmatory momentum oscillator such as CCI or MOM, this indicator generates more precise and timely signals for entering trades.
The indicator offers a comprehensive set of entry conditions for both Buy and Sell entries:
• For Buy entries, it checks for oversold conditions based on RSI levels, and detects bullish divergence patterns while oversold and it identifies upward crossovers in the selected entry signal source (CCI or Momentum).
• Similarly, for Sell entries, it identifies downward crossovers of the CCI or Mom, after the recent overbought conditions, and bearish divergence patterns inside the overbought RSI.
To refine the entry signals even further, the indicator utilizes a mean reversion filter. Traders can choose to display signals that occur inside or outside the upper and lower mean reversion bands:
• Range Entries are indicating potential buying opportunities near the lower band and selling opportunities near the upper band. This is based on the concept of mean reversion, which suggests that prices tend to return to the average when they reach the upper or lower bands. By focusing on these signals, traders can take advantage of price movements that have a higher probability of reversing towards the mean.
• Extreme Entries, on the other hand, represent signals that occur outside of the bands, signaling potential pullbacks during strong trends. By entering positions only at extreme highs or lows, traders can avoid getting caught in the middle of the trend. This approach helps traders capitalize more favorable trading opportunities which have a high reward-risk ratio.
Trend Filter acts as a directional bias for the entry signals. When enabled, long and short entry conditions are filtered based on the relationship between the closing price and the EMA.
Traders have the flexibility to customize, tweak the indicator filter and values in the settings according to their preferences strategies and traded assets, tailoring the signals to their specific needs. The script sets alert conditions to trigger alerts for buy, sell, or both entry signals. This indicator can be used in conjunction with price action or other technical analysis tools for confirmation and better trading decisions.
I created this indicator for my own use, and I share this for informational purposes only. It does not constitute financial advice so use at your own risk and consider your financial situation before making any trading decisions. The indicator's accuracy is not guaranteed, and past performance is not indicative of future results.
I appreciate your feedback on this indicator. As I am new to script development, I am open to comments and suggestions to improve it. If you encounter any issues while using this indicator, please let me know in the comments section. If you find it helpful, I kindly ask for your support in boosting it. Thank you for your cooperation.
Edri Extreme Points Buy & SellEDRI EXTREME POINTS BUY & SELL INDICATOR
This Buy and Sell (non-repainting) indicator uses signals based on the combined CCI/Momentum and RSI indicators and optional regular divergence.
The idea of the indicator is to look for a potential reversal after the price reached extreme points (overbought or oversold) and signals an entry when the price shows signs of momentum for reversal.
Optionally, it considers finding a divergence while RSI is at the extreme levels to improve the predictability of a possible reversal.
Additionally, the indicator includes a simple Mean Reversion visual on the chart to assist users in identifying extreme price levels and potential reversal opportunities. It features upper and lower bands that can be optionally plotted, showing calculated values where price bounces at those extreme levels.
The purpose of these bands is to help traders avoid getting trapped in the middle of a trend and to guide them to buy low and sell high. (It's important to note that this is purely a visual aid and does not impact the generation of trade signals.)
By utilizing the Mean Reversion bands alongside the entry conditions, traders can gain insights into potential price reversals and make more informed decisions about when to enter or exit trades.
Buy and Sell Entry conditions:
• The indicator looks at the CCI/Momentum indicator to turn positive (if buy) or negative (if sell) after the RSI was overbought or oversold in the recent past.
• It also checks if there is a 3-period regular bullish divergence in the RSI (if buy), or regular bearish divergence (if sell) and consider these in the entry condition.
• If these conditions are met, this indicator suggests that it may be a good time to enter a trade.
In summary this is how this indicator works:
• The indicator takes input settings such as the choice between using CCI or Momentum as the entry signal source, length parameters for CCI/Momentum, RSI levels for overbought and oversold conditions, RSI length, and options to plot mean reversion bands on the chart.
• It calculates the CCI and Momentum and RSI values based on user-defined length..
• It checks for regular bullish and bearish divergences (3 periods) in the RSI if the option is enabled.
• The script plots shapes on the chart to indicate the buy and sell signals based on the entry conditions.
• If the mean reversion bands option is enabled, it calculates the mean reversion, standard deviation, upper band, and lower band values.
• It also plots the upper band, mean reversion line, and lower band on the chart if the mean reversion bands option is enabled.
• This indicator includes alert conditions to generate alerts for the buy and sell signals.
• On top of that, users can opt to use only one alert for both buy and sell signals. (This can save Trading view subscribers with limited alerts.)
Important! Please do not consider everything you read here as financial advice. Additionally, do not rely solely on indicators for making your trading decisions. It is important to note that no indicator or strategy is perfect. Therefore, it is always recommended to backtest everything and practice proper risk management.
I appreciate your feedback on this indicator. As I am new to script development, I am open to comments and suggestions to improve it. If you encounter any issues while using this indicator, please let me know in the comments section. If you find it helpful, I kindly ask for your support in boosting it. Thank you for your cooperation.
Advanced Exponential Smoothing Indicator (AESI) [AstrideUnicorn]The Advanced Exponential Smoothing Indicator (AESI) provides a smoothed representation of price data using the exponential smoothing technique. It helps traders identify the overall trend and potential reversal points in the market.
SETTINGS
Length: The number of periods used for the calculation of the exponential moving average (EMA). Higher values provide a smoother result but may lag behind price movements.
Alpha: The smoothing factor that determines the weight of the recent price data in the smoothing calculation. Higher values give more weight to recent data, resulting in a more responsive indicator.
Cloud Mode: Determines whether to display a cloud between the AESI line and the EMA line. When enabled, the cloud represents bullish (green) and bearish (red) market conditions.
HOW TO USE
The AESI indicator consists of a single line that represents the advanced exponential smoothing of the price data. It aims to provide a smoother version of the price series, reducing noise and revealing the underlying trend.
Bullish Condition: When the AESI line is above the EMA line, it indicates a bullish market condition. Traders may consider looking for buying opportunities or holding onto existing long positions.
Bearish Condition: When the AESI line is below the EMA line, it suggests a bearish market condition. Traders may consider looking for selling opportunities or holding onto existing short positions.
Optional Cloud Mode:
Enabling the cloud mode allows you to visualize bullish and bearish market conditions more clearly. The cloud appears between the AESI line and the EMA line, providing a visual representation of the prevailing market sentiment.
Bullish Cloud: When the AESI line is above the EMA line, the cloud is green, indicating a potential bullish market condition.
Bearish Cloud: When the AESI line is below the EMA line, the cloud is red, indicating a potential bearish market condition.
Note: The AESI indicator is most effective when used in conjunction with other technical analysis tools and indicators to confirm trading signals and make informed trading decisions.
Adjusting the Parameters:
You can adjust the Length and Alpha parameters to find the best ones for different timeframes and market conditions. Experimenting with different parameter values can help you find the optimal settings for your trading strategy.
It is recommended to backtest the AESI indicator on historical price data and evaluate its performance before using it in live trading. Remember that no indicator can guarantee profitable trades, and it is important to use risk management techniques and exercise caution when making trading decisions.
Trend hunter strategy - buy & sellThe indicator combines multiple technical indicators and conditions to generate buy and sell signals.
Here's how the indicator works and how to use it:
Strategy Selection:
The indicator provides a dropdown menu to choose the type of strategy. The available options are "Pullback" and "Simple."
Supertrend Settings:
The Supertrend indicator is used to identify the trend direction.
The indicator takes two input parameters:
ATR Length: Specifies the length of the Average True Range (ATR) used in the Supertrend calculation. The default value is 10.
Factor: Specifies the factor used in the Supertrend calculation. The default value is 3.0.
EMA Settings:
The indicator also includes an Exponential Moving Average (EMA) condition.
You can enable or disable the EMA condition using the "Ema Condition On/Off" checkbox.
If enabled, the indicator calculates an EMA based on the close price.
You can specify the length of the EMA using the "Ema Length" input parameter. The default value is 200.
RSI Settings:
The Relative Strength Index (RSI) indicator is used to generate additional conditions.
You can enable or disable the RSI condition using the "Rsi Condition On/Off" checkbox.
If enabled, the indicator calculates the RSI based on the close price.
You can specify the length of the RSI using the "Rsi Length" input parameter. The default value is 14.
Additionally, you can set the overbought and oversold levels for the RSI using the "RSI BUY Level" and "RSI SELL Level" input parameters, respectively. The default value for both is 50.
Final Conditions:
The indicator combines the Supertrend, EMA, and RSI conditions to generate buy and sell signals.
The specific conditions depend on the chosen strategy:
For the "Simple" strategy, the buy condition is when the Supertrend is in an up trend, not in a previous long position, the RSI is above the overbought level, and the close price is above the EMA.
For the "Pullback" strategy, the buy condition is when there is a cross under of the previous low with the Supertrend, the Supertrend is in an up trend, the RSI is above the overbought level, and the close price is above the EMA.
The sell conditions are the opposite of the respective buy conditions.
Backtest Period:
You can specify the start and end dates for the backtesting using the "Start calculations from" and "End calculations" inputs, respectively. The default start date is "2005-01-01" and the default end date is "2045-03-01." (this is work in progress) Still working on the table part, it is a bit tricky.
Trade Direction:
You can choose the trade direction using the "Trade Direction" input parameter. The available options are "Long," "Short," and "Both."
Depending on the selected trade direction, the indicator will generate signals accordingly.
Visual Display:
The indicator plots the Supertrend line on the price chart.
Buy signals are shown as green labels below the price bars.
Sell signals are shown as red labels above the price bars.
Adjust the input parameters according to your preferences, and then apply the indicator to a chart to see the generated signals. Please note that this indicator should be used for educational purposes only and should be thoroughly tested before using it for real trading.
HK Percentile Interpolation One
This script is designed to execute a trading strategy based on Heikin Ashi candlesticks, moving averages, and percentile levels.
Please note that you should keep your original chart in normal candlestick mode and not switch it to Heikin Ashi mode. The script itself calculates Heikin Ashi values from regular candlesticks. If your chart is already in Heikin Ashi mode, the script would be calculating Heikin Ashi values based on Heikin Ashi values, which would produce incorrect results.
The strategy begins trading from a start date that you can specify by modifying the `startDate` parameter. The format of the date is "YYYY MM DD". So, for example, to start the strategy from January 1, 2022, you would set `startDate = timestamp("2022 01 01")`.
The script uses Heikin Ashi candlesticks, which are plotted in the chart. This approach can be useful for spotting trends and reversals more easily than with regular candlestick charts. This is particularly useful when backtesting in TradingView's "Rewind" mode, as you can see how the Heikin Ashi candles behaved at each step of the strategy.
Buy and sell signals are generated based on two factors:
1. The crossing over or under of the Heikin Ashi close price and the 75th percentile price level.
2. The Heikin Ashi close price being above certain moving averages.
You have the flexibility to adjust several parameters in the script, including:
1. The stop loss and trailing stop percentages (`stopLossPercentage` and `trailStopPercentage`). These parameters allow the strategy to exit trades if the price moves against you by a certain percentage.
2. The lookback period (`lookback`) used to calculate percentile levels. This determines the range of past bars used in the percentile calculation.
3. The lengths of the two moving averages (`yellowLine_length` and `purplLine_length`). These determine how sensitive the moving averages are to recent price changes.
4. The minimum holding period (`holdPeriod`). This sets the minimum number of bars that a trade must be kept open before it can be closed.
Please adjust these parameters according to your trading preferences and risk tolerance. Happy trading!
Multi-Divergence Buy/Sell IndicatorThe "Multi-Divergence Buy/Sell Indicator" is a technical analysis tool that combines multiple divergence signals from different indicators to identify potential buy and sell opportunities in the market. Here's a breakdown of how the indicator works and how to use it:
Input Parameters:
RSI Length: Specifies the length of the RSI (Relative Strength Index) calculation.
MACD Short Length: Specifies the short-term length for the MACD (Moving Average Convergence Divergence) calculation.
MACD Long Length: Specifies the long-term length for the MACD calculation.
MACD Signal Smoothing: Specifies the smoothing length for the MACD signal line calculation.
Stochastic Length: Specifies the length of the Stochastic oscillator calculation.
Stochastic Overbought Level: Defines the overbought level for the Stochastic oscillator.
Stochastic Oversold Level: Defines the oversold level for the Stochastic oscillator.
Calculation of Indicators:
RSI: Calculates the RSI based on the specified RSI Length.
MACD: Calculates the MACD line, signal line, and histogram based on the specified MACD parameters.
Stochastic: Calculates the Stochastic oscillator based on the specified Stochastic parameters.
Divergence Detection:
RSI Divergence: Identifies a bullish divergence when the RSI crosses above its 14-period simple moving average (SMA).
MACD Divergence: Identifies a bullish divergence when the MACD line crosses above the signal line.
Stochastic Divergence: Identifies a bullish divergence when the Stochastic crosses above its 14-period SMA.
Buy and Sell Conditions:
Buy Condition: Triggers a buy signal when all three divergences (RSI, MACD, and Stochastic) occur simultaneously.
Sell Condition: Triggers a sell signal when both RSI and MACD divergences occur, but Stochastic divergence does not occur.
Plotting Buy/Sell Signals:
The indicator plots green "Buy" labels below the price bars when the buy condition is met.
It plots red "Sell" labels above the price bars when the sell condition is met.
Usage:
The indicator can be used on any timeframe and for any trading instrument.
Look for areas where all three divergences (RSI, MACD, and Stochastic) align to generate stronger buy and sell signals.
Consider additional technical analysis and risk management strategies to validate the signals and manage your trades effectively.
Remember, no indicator guarantees profitable trades, so it's essential to use this indicator in conjunction with other tools and perform thorough analysis before making trading decisions.
Feel free to ask any questions
Fib top and bottom Hunter - No Repaint "Top and bottom Hunter" indicator combines two popular technical analysis tools, Fibonacci retracement levels and the Relative Strength Index (RSI), to identify potential trading opportunities in the market.
Fibonacci retracement levels are based on the Fibonacci sequence, a mathematical series where each number is the sum of the two preceding ones. In trading, Fibonacci retracement levels are used to identify potential support and resistance levels based on the recent price action. The indicator uses two Fibonacci levels, fib_0 and fib_1, which are typically set to 0.382 and 0.618, respectively. These levels represent common retracement ratios.
To calculate the Fibonacci levels, the indicator considers the highest and lowest prices within a specified range, typically the highest and lowest of the last two bars. It calculates the fib_range, which is the difference between the highest and lowest prices. Then, fib_level_0 and fib_level_1 are determined by subtracting the Fibonacci ratios from the highest price.
The RSI is a momentum oscillator that measures the speed and change of price movements. It helps identify overbought and oversold conditions in the market. The RSI parameters used in this indicator are rsi_length (length of the RSI calculation), rsi_overbought (upper threshold indicating overbought conditions), and rsi_oversold (lower threshold indicating oversold conditions). The RSI value is calculated based on the closing prices.
The indicator generates buy and sell signals based on specific conditions:
Buy Condition: A buy signal is triggered when the RSI crosses above the oversold level (rsi_oversold) and the closing price is higher than fib_level_1. This indicates a potential reversal or bounce from the Fibonacci support level.
Sell Condition: A sell signal is triggered when the RSI crosses below the overbought level (rsi_overbought) and the closing price is lower than fib_level_0. This suggests a potential reversal or pullback from the Fibonacci resistance level.
In summary, this indicator combines the power of Fibonacci retracement levels and the RSI to identify potential trading opportunities. It helps traders find confluence between the Fibonacci support or resistance levels and the RSI readings, indicating potential trend reversals or bounces. Traders can use this information to make informed decisions about entering or exiting positions in the market.
Feel free to change the settings for what works best for you and use this with other confluences. I personally use RSI overbought and oversold values as 80 and 20
Inside candle (Inside Bar) Strategy- by smartanuThe Inside Candle strategy is a popular price action trading strategy that can be used to trade in a variety of markets. Here's how you can trade the Inside Candle strategy using the Pine script code provided:
1. Identify an Inside Candle: Look for a candlestick pattern where the current candle is completely engulfed within the previous candle's high and low. This is known as an Inside Candle.
2. Enter a Long Position: If an Inside Candle is identified, enter a long position at the open of the next candle using the Pine script code provided.
3. Set Stop Loss and Take Profit: Set a stop loss at a reasonable level to limit your potential losses if the trade goes against you. Set a take profit at a reasonable level to take profit when the price reaches the desired level.
4. Manage the Trade: Monitor the trade closely and adjust the stop loss and take profit levels if necessary. You can use the Pine script code to automatically exit the trade when the stop loss or take profit level is hit.
5. Exit the Trade: Exit the trade when the price reaches the take profit level or the stop loss level is hit.
It's important to note that the Inside Candle strategy is just one of many strategies that traders use to trade the markets. It's important to perform your own analysis and use additional indicators before making any trades. Additionally, it's important to practice proper risk management techniques and never risk more than you can afford to lose.
Chandelier Exit ZLSMA StrategyIntroducing a Powerful Trading Indicator: Chandelier Exit with ZLSMA
If you're a trader, you know the importance of having the right tools and indicators to make informed decisions. That's why we're excited to introduce a powerful new trading indicator that combines the Chandelier Exit and ZLSMA: two widely-used and effective indicators for technical analysis.
The Chandelier Exit (CE) is a popular trailing stop-loss indicator developed by Chuck LeBeau. It's designed to follow the price trend of a security and provide an exit signal when the price crosses below the CE line. The CE line is based on the Average True Range (ATR), which is a measure of volatility. This means that the CE line adjusts to the volatility of the security, making it a reliable indicator for trailing stop-losses.
The ZLEMA (Zero Lag Exponential Moving Average) is a type of exponential moving average that's designed to reduce lag and improve signal accuracy. The ZLSMA takes into account not only the current price but also past prices, using a weighted formula to calculate the moving average. This makes it a smoother indicator than traditional moving averages, and less prone to giving false signals.
When combined, the CE and ZLSMA create a powerful indicator that can help traders identify trend changes and make more informed trading decisions. The CE provides the trailing stop-loss signal, while the ZLSMA provides a smoother trend line to help identify potential entry and exit points.
In our indicator, the CE and ZLSMA are plotted together on the chart, making it easy to see both the trailing stop-loss and the trend line at the same time. The CE line is displayed as a dotted line, while the ZLSMA line is displayed as a solid line.
Using this indicator, traders can set their stop-loss levels based on the CE line, while also using the ZLSMA line to identify potential entry and exit points. The combination of these two indicators can help traders reduce their risk and improve their trading performance.
In conclusion, the Chandelier Exit with ZLSMA is a powerful trading indicator that combines two effective technical analysis tools. By using this indicator, traders can identify trend changes, set stop-loss levels, and make more informed trading decisions. Try it out for yourself and see how it can improve your trading performance.
Warning: The results in the backtest are from a repainting strategy. Don't take them seriously. You need to do a dry live test in order to test it for its useability.
-
Here is a description of each input field in the provided source code:
length: An integer input used as the period for the ATR (Average True Range) calculation. Default value is 1.
mult: A float input used as a multiplier for the ATR value. Default value is 2.
showLabels: A boolean input that determines whether to display buy/sell labels on the chart. Default value is false.
isSignalLabelEnabled: A boolean input that determines whether to display signal labels on the chart. Default value is true.
useClose: A boolean input that determines whether to use the close price for extrema calculations. Default value is true.
zcolorchange: A boolean input that determines whether to enable rising/decreasing highlighting for the ZLSMA (Zero-Lag Exponential Moving Average) line. Default value is false.
zlsmaLength: An integer input used as the length for the ZLSMA calculation. Default value is 50.
offset: An integer input used as an offset for the ZLSMA calculation. Default value is 0.
-
Ty for checking this out and good luck on your trading journey! Likes and comments are appreciated. 👍
--
Credits to:
▪ @everget – Chandelier Exit (CE)
▪ @netweaver2022 – ZLSMA
BUY/SELL + ADVANCE DECLINEThis script is a custom trading view indicator that helps to identify potential buy and sell signals based on the RSI (Relative Strength Index) and SMA (Simple Moving Average) indicators. The script also identifies potential reversals using a combination of RSI and price action. It plots buy, sell, and reversal signals on the chart along with an SMA line. Additionally, it provides alerts based on the buy, sell, and reversal conditions.
Changes made to the original script:
Fixed the undeclared identifier 'c' error by calculating the difference between the current closing price and the previous closing price: c = close - close .
Added an "ADD Value Floating Label" to the chart. The label shows the difference between the current and previous closing prices (ADD value) along with a "Bullish" or "Bearish" indicator based on the value of 'c'. The label is positioned at the top right of the visible chart area and remains static.
Here's a summary of the major components of the script:
Input settings: Define the input parameters for RSI and SMA.
Calculation of RSI and SMA: Compute the RSI and SMA values based on the input parameters.
Color definitions: Define colors for different conditions and levels.
Condition definitions: Define various conditions for buy, sell, reversal, and other criteria.
Buy and sell conditions: Determine buy and sell signals based on RSI, SMA, and price action.
Reversal conditions: Identify potential reversals using RSI and price action.
Plot signals: Display buy, sell, and reversal signals on the chart.
Bar colors: Color the bars based on the identified signals.
Plot SMA: Display the SMA line on the chart.
Alert conditions: Set up alerts for buy, sell, and reversal conditions.
ADD Value Floating Label: Add a label to the chart showing the ADD value and a "Bullish" or "Bearish" indicator.
Buy / Sell Fractal Algorithm with SL Line GenerationThis algorithm is designed for usage across indices.
How it works?
The algorithm uses a variation of fractals, momentum, RSI and LRSI to determine a trends direction.
The Relative Strength Index (RSI) is a momentum-based oscillator used to measure the speed (velocity) and change (magnitude) of directional price movements. It provides a visual means to monitor both the current and historical strength and weakness of a particular market. The strength or weakness is based on closing prices over the duration of a specified trading period, creating a reliable metric of price and momentum changes
Momentum in trading refers to the direction and magnitude of price. Momentum plays a key role in assessing trend strength, and it is important to know when a trend is slowing down. Less momentum does not always lead to a reversal, but it does signal that something is changing, and the trend may consolidate or reverse
Fractals are patterns within price changes which are repeated across thousands of bars. Examples of fractals include the golden ratio, PHI and the spirals of the milk way. They are quite literally a universal concept.
Basics of usage:
When a bullish trend is detected; the algorithm will generate a green "SL Line" at a calculated point, which can be interpreted as an invalidation line.
If the price goes below this line, the bullish trend is invalidated. So long as it holds, the bullish trend is true until the next detection change.
When a bearish trend is detected; the algorithm will generate a red "SL Line", at a calculated point, which can be interpreted as an invalidation line.
If the prices goes above this line, the bearish trend is invalidated. So long as it holds, the bearish trend is true until the next detection change.
When a given trend is invalidated, the SL Line turns yellow and you enter a "pause zone", where neither a bearish nor bullish trend is calculated.
This resets itself on the next trend detection.
Additional information:
I have coded my own backtest to this algorithm, along with plotting the profit / loss of each generated trade.
The profit is calculated by the difference between the open bar of the trade after a long ( or short ) and the following trade.
If we are calculating a short, the resulting value is then multiplied by -1 to get a positive integer.
For calculating a loss we take the value of the open bar of the trade that generates a long, and take the difference between this and the SL line, and similarly for short positions. The code assumes the user is placing their SL at the indicated line.
Within the input settings there are a few customisation options:
Alpha & Fractal Energy Length & Source - Should not be changed.
Highly bands crossover? - Has no visible effect whether on or off. It refers to the fractal chart which in this iteration is not visible and rather a backend mechanic.
Apply fractal energy? - Should generally be left turned on. This is a noise reduction. Disabling will result in over-trading.
Apply normalization? - Has no impact, is solely used to make the fractal values more human-readable rather than decimal format.
Offset - refers to the offset value of the SL Line generations. This should be set to a value that gives you enough breathing room, and remember to include any spreads! Default is 0.2, written in %
Trading hours - This simply gives a session input for the trading hours you want to trade within, and then colours the background green for that session. Trading 24/7 is never a wise strategy, stick to whatever is most optimal for you.
Leverage - Whatever leverage you are using. Default is x20. This will affect the profit / loss calculations accordingly.
Start equity - refers to the equity value you want to backtest with. Some assets will generate NA for this in the backtest label explained later.
Label customisation options.
Note that the backtest label is by default hidden, and appears when you hover over the black label at the current bar. When enabled to visible, it will show a large text label that may cover your chart screen more than you wish.
Alerts -
There are dozens of alert functionalities here; first are the timeframe assignments for each alert, set by default to 2hrs.
These timeframes then affect the asset you select in the corresponding setting.
In total there are 8 additional assets you can set alerts for.
Once you have assigned the timeframe and asset for an alert, you can then check the tick box for that individual alert.
Once done, you set the alert as normal through the tradingview alerts window. Remember to set "alert function calls only"
-
Timers:
I have added some functionality for timers to be set, values are in minutes. These work on the exact time of placement. Do not change the extra symbol formula option.
-
Note that this backtest is not intended as a replacement for tradingview backtest, nor is there a guarantee that historical results are to be replicated in the future. Trading is inherently risky.
SPY 4 Hour Swing TraderThe purpose of this script is to spot 4 hour pivots that indicate ~30 trading day swings. As VIX starts to drop options trading will get more boring and as we get back on the bull and can benefit from swing trading strategy. Swing trading doesn't make a whole lot of sense when VIX is above 28. Seems to get best results on 4 hour chart for this one. This indicator spots a go long opportunity when the 5 ema crosses the 13 ema on the 4 hour along with the RSI > 50 and the ADX > 20 and Stoichastic values (smoothed line < 80 or line < 90) and close > last candle close and the True Range < 6. It also spots uses a couple different means to determine when to exit the trade. Sell condition is primarily when the 13 ema crosses the 5 ema and the MACD line crosses below the signal line and the smoothed Stoichastic appears oversold (greater than 60) and slop of RSI < -.2. Stop Losses and Take Profits are configurable in Inputs along with ability to include short trades plus other MACD and Stoichastic settings. If a stop loss is encountered the trade will close. Also once twice the expected move is encountered partial profits will taken and stop losses and take profits will be re-established based on most recent close. Also a VIX above 28 will trigger any open positions to close. If trying to use this for something other than SPXL it is best to update stop losses and take profit percentages and check backtest results to ensure proper levels have been selected and the script gives satisfactory results.