(1-20)Dashboard trendlines PriceThis is a script about 20 trading pairs with trendline.
-on each chart of a trading pair, there is only one trendline pair: 1 uptrendline and 1 downtrendline
-so when the statistics on the table also show the column of the uptrend and the column of the downtrend
-When the price approaches any trendline but the ratio is 1%, that trendline will be colored blue (downtrend), red (uptrend)
-the column above T.line(below T.line) is the value of the current trendline compared to the closing price of the candle
-The Break up (Break down) column when the price breaks will show the green heart (break up), the red heart break (break down) and the percentage value when breaking through the point of the trendline.
-price column is the current price of the candle
-especially when a candle has closed above the trendline (assuming an uptrend), then from the 2nd tree to the current , it will count according to memory so that traders know when the price broke, and how many candles already.
-The breakdown parameter is displayed (for example, 3|8|10), which means that the price has broken through 10 candles, of which 8 trees are closing above the breakout point, and the last 3 are closing above. break point
-In addition, when displaying 3 parameters as above, the next column (above/below T.line) will display the percentage from when the price breaks that point to the current price of the candle.
-you can change the time in Resolution indicator settings to show multiple time arcs
Thank you everyone for your interest and trust
- 5 pairs are free for traders :https://vn.tradingview.com/script/KGSjrLC3/
---------------------------------------------------------------------------------
Vietnamese
Đây là script về bảng thống kê 20 cặp giao dịch với đường trendline .
-trên mỗi biểu đồ của cặp giao dịch chỉ tồn tại duy nhất 1 cặp trendline là: 1trendline tăng và 1 trendline giảm
-vì vậy khi thống kê trên bảng cũng hiển thị cột của trend tăng và cột của trend giảm
-khi giá tiến gần đến 1 đường trendline bất kì mà tỉ lệ còn 1% thì đường trendline đó tô màu xanh(trend giảm) ,màu đỏ(trend tăng)
-cột above T.line(below T.line) là giá trị của đường trendline hiện tại so với giá đóng cửa của nến
-cột Break up(Break down) khi giá phá vỡ sẽ thể thiện trái tim xanh(phá vỡ lên),trái tim đỏ vỡ(phá vỡ xuống) và giá trị phần trăm khi phá qua điểm của trendline.
-cột giá là giá hiện tại của nến
-đặc biệt khi 1 cây nến đã đóng cửa trên đường trendline(giả sử trend tăng) thì từ cây thứ 2 đến hiện tại nó sẽ đếm theo bộ nhớ để các trader biết được giá đã phá khi nào,và qua bao nhiêu nến rồi.
-thông số khi phá vỡ hiển thị (ví dụ là 3|8|10) thì hiểu là giá đã phá vỡ qua 10 nến, trong đó có 8 cây đóng cửa trên điểm phá vỡ,và 3 cây gần nhất đang đóng cửa trên điểm phá vỡ
-ngoài ra khi hiện 3 thông số như trên thì cột bên cạnh (above/below T.line) sẽ hiển thị được số phần trăm tính từ khi giá phá vỡ điểm đó đến giá hiện tại của cây nến.
-các bạn có thể thay đổi thời gian trong cài đặt chỉ báo Resolution để hiển thị nhiều cung thời gian
Cảm ơn mọi người đã quan tâm và tin dùng
Cerca negli script per "trendline"
Simple Trendlines📈 Trendlines, made easy.
Simple Trendlines is a carefully made library that provides an easy and accessible way to draw trendlines on the chart.
Containing only 10 properties and 2 methods, the implementation is designed to be understandable through an object-oriented structure and provides developers the opportunity to expand without having to deal with slope calculation while also ensuring that there's no leakage between the trendlines before they're drawn.
Developers only need to provide 5 expressions to get everything up in running. This includes the following but is not limited to
The x-axis
Point A (Y1 Value)
Point B (Y2 Value)
A condition to draw the line
A condition to keep the trendline under continuation
Automatic x-axis calculation is not a built-in feature due to the inconsistency it could bring.
📕 Quick Example
import HoanGhetti/SimpleTrendlines/1 as tl
input_len = input.int(defval = 10)
pivotLow = fixnan(ta.pivotlow(input_len, input_len))
xAxis = ta.valuewhen(ta.change(pivotLow), bar_index, 0) - ta.valuewhen(ta.change(pivotLow), bar_index, 1)
prevPivot = ta.valuewhen(ta.change(pivotLow), pivotLow, 1)
pivotCondition = ta.change(pivotLow) and pivotLow > prevPivot
plData = tl.new(x_axis = xAxis, offset = input_len)
plData.drawLine(pivotCondition, prevPivot, pivotLow)
plData.drawTrendline(close > 0)
plData.lines.trendline.set_style(line.style_dashed)
plData.lines.trendline.set_width(2)
plData.lines.startline.set_width(2)
Excluding the styling at the bottom, that was only 8 lines of code which yields the following result.
⏳ Before continuing
The library does not support block-scoped execution. Conditions must be declared before and integrated as a parameter. This doesn't limit any capabilities and only involves thinking logically about precedence. It was made this way for code readability and to keep things organized.
The offset value inside the TrendlineSettings object can potentially affect performance (although very minimal) if you're using strict mode. When using strict mode, it loops through historical values to then do backend calculations.
🔽 Getting Started 🔽
Creating trendlines without a library isn't a hard task. However, the library features a built-in system called strict mode. We'll dive further into this below.
Creating an Instance
You can create an instance of the library by calling the new() function. Passing an identifier is conventionally mandatory in this case so you can reference properties and methods.
import HoanGhetti/SimpleTrendlines/2 as tl
lineData = tl.new(int x_axis, int offset, bool strictMode, int strictType)
___
int x_axis (Required) The distance between point A and point B provided by the user.
int offset (Optional) The offset from x2 and the current bar_index. Used in situations where conditions execute ahead of where the x2 location is such as pivót events.
bool strictMode (Optional) Strict mode works in the backend of things to ensure that the price hasn't closed below the trendline before the trendline is drawn.
int strictType (Optional) Only accepts 0 and 1, 0 ensures that the price during slope calculation is above the line, and 1 ensures that the price during slope calculation is below the line.
The Initial Line
After instantiating the library, we can go ahead use the identifer we made above and create an instance of our initial line by calling the drawLine() method.
lineData.drawLine(bool condition, float y1, float y2, float src)
___
bool condition (Required) The condition in order to draw a new line.
float y1 (Required) The y-value of point A.
float y2 (Required) The y-value of point B.
float src (Optional) Determines which value strict mode will actively check for leakage before a trendline is drawn.
Typically used if you're not referencing OHLC values for your y-values, or you want to check for another value to exceed the line besides using the close value.
The Trendline
The trendline that gets drawn solely uses the values of the initial line and can be called using the drawTrendline() method. The library enforces a condition as a parameter in order to maintain simplicity.
lineData.drawTrendline(bool condition)
___
bool condition (Required) The condition in order to maintain and continue drawing the trendline.
⚙️ Features
🔹 Automatic Slope Calculation
In the background, the library calculates the next Y2 and X2 values on every tick for the trendline. Preventing the developer from having to do such a process themself.
🔹 Object-Oriented
Each object contains manipulative properties that allow the developer to debug and have the freedom they want.
🔹 Enforced Error Checking
Runtime errors have been put in place to ensure you're doing things correctly.
🔹 Strict Mode & Offset
Strict mode can only be used when the offset value is over 0. It's a feature that's only meant to function under scenarios where a condition executes further than where the X2 is relative to the current bar_index value.
Let's think about pivot systems. As you're aware, pivot events are detected based on historical factors. If a swing low occurred nth bars ago, then the pivot condition will execute at the current bar_index instead of executing nth bars back.
Now because of this, what if you wanted to draw a trendline when the pivot event is executed? The offset value takes care of this just as you would when developing your other scripts, basically how we always do bar_index - n. However, what does this mean for strict mode?
The photo below represents the logic behind the execution.
When looking at this image, imagine this just happened, the event just executed and the trendline is now drawn. Pay attention to all the values inside the surrounding box. As you can see there are some candles that closed below the trendline before the trendline was drawn.
From what I can see 5-6 candles closed below the trendline during slope calculation. The goal of strict mode is to be a provisional system that prevents such occurrences from happening.
Here's a photo with strict mode on.
🔹 Strict Type
A parameter used in the new() function that acts as a representation of what strict mode should calculate for. It accepts only two values, 0 and 1.
0 - Ensures that all candles have closed above the trendline before the trendline is drawn.
1 - Ensures that all candles have closed below the trendline before the trendline is drawn.
In the most recent photo above, I used 0 for strict type, since I was wanting to have a clean trendline and ensure that not a single candlestick closed below.
If you want to reference something else besides the close value during strict mode calculation, you can change it in the drawLine() method.
If it's still difficult to understand, think 0 for pivot lows, and 1 for pivot highs.
📕 Methods and Property Inheritance
The library isn't crazy, but hopefully, it helps.
That is all.👍
Dashboard trendlines Price(ichimoku14642)Happy new year 2023
Dedicated to traders, the trendline indicator of 5 trading pairs is automatically listed in this table. Wish success
-on each chart of a trading pair, there is only one trendline pair: 1 uptrendline and 1 downtrendline
-so when the statistics on the table also show the column of the uptrend and the column of the downtrend
-When the price approaches any trendline but the ratio is 1%, that trendline will be colored blue (downtrend), red (uptrend)
-the column above T.line(below T.line) is the value of the current trendline compared to the closing price of the candle
-The Break up (Break down) column when the price breaks will show the green heart (break up), the red heart break (break down) and the percentage value when breaking through the point of the trendline.
-price column is the current price of the candle
-SYMBOL is all taken from Binance in the perpetual contract
-especially when a candle has closed above the trendline (assuming an uptrend), then from the 2nd tree to the current , it will count according to memory so that traders know when the price broke, and how many candles already.
-The breakdown parameter is displayed (for example, 3|8|10), which means that the price has broken through 10 candles, of which 8 trees are closing above the breakout point, and the last 3 are closing above. break point
-In addition, when displaying 3 parameters as above, the next column (above/below T.line) will display the percentage from when the price breaks that point to the current price of the candle.
Thank you everyone for your interest and trust
Đây là script về bảng thống kê đường trendline .
-trên mỗi biểu đồ của cặp giao dịch chỉ tồn tại duy nhất 1 cặp trendline là: 1trendline tăng và 1 trendline giảm
-vì vậy khi thống kê trên bảng cũng hiển thị cột của trend tăng và cột của trend giảm
-khi giá tiến gần đến 1 đường trendline bất kì mà tỉ lệ còn 1% thì đường trendline đó tô màu xanh(trend giảm) ,màu đỏ(trend tăng)
-cột above T.line(below T.line) là giá trị của đường trendline hiện tại so với giá đóng cửa của nến
-cột Break up(Break down) khi giá phá vỡ sẽ thể thiện trái tim xanh(phá vỡ lên),trái tim đỏ vỡ(phá vỡ xuống) và giá trị phần trăm khi phá qua điểm của trendline.
-cột giá là giá hiện tại của nến
-SYMBOL là toàn bộ lấy của sàn Binance trong hợp đồng vĩnh cửu
-đặc biệt khi 1 cây nến đã đóng cửa trên đường trendline(giả sử trend tăng) thì từ cây thứ 2 đến hiện tại nó sẽ đếm theo bộ nhớ để các trader biết được giá đã phá khi nào,và qua bao nhiêu nến rồi.
-thông số khi phá vỡ hiển thị (ví dụ là 3|8|10) thì hiểu là giá đã phá vỡ qua 10 nến, trong đó có 8 cây đóng cửa trên điểm phá vỡ,và 3 cây gần nhất đang đóng cửa trên điểm phá vỡ
-ngoài ra khi hiện 3 thông số như trên thì cột bên cạnh (above/below T.line) sẽ hiển thị được số phần trăm tính từ khi giá phá vỡ điểm đó đến giá hiện tại của cây nến.
Cảm ơn mọi người đã quan tâm và tin dùng
All Possible Trendlines W/AlertsCore Functionality:
Trendline Detection: The system uses a proprietary algorithm that goes beyond traditional pivot point connection methods. It analyzes price action patterns and market structure to identify potential trendlines that many traders might overlook. This includes not just obvious trendlines, but also subtle ones that could become significant in the future.
Significance Evaluation: Unlike conventional indicators that treat all trendlines equally, the system employs a unique scoring system to evaluate each trendline's importance. This system considers factors such as the number of touch points, the length of the trendline, and its historical reliability in predicting price movements. This allows traders to focus on the most relevant trendlines.
Dynamic Updating: The AITI continuously reassesses and adjusts trendlines as new price data becomes available. This dynamic approach ensures that the indicator adapts to changing market conditions, providing up-to-date and relevant information.
What Makes It Original:
The AITI's originality lies in its holistic approach to trendline analysis. While most indicators focus on identifying a few key trendlines, this system aims to present a complete picture of all possible trendlines in the market. This comprehensive view allows traders to:
- Gain deeper insights into market structure and potential price movements.
- Identify less obvious but potentially significant trendlines that other traders might miss.
- Understand the relative importance of different trendlines, rather than treating all trendlines as equally significant.
The indicator's ability to dynamically update and re-evaluate trendlines in real-time sets it apart from static trendline tools. This ensures that traders always have the most current and relevant information at their disposal.
By providing a more nuanced and complete view of trendlines, the AITI enables traders to make more informed decisions based on a deeper understanding of market structure. This approach to trendline analysis is not readily available in open-source alternatives, making the AITI a valuable tool for traders seeking a more comprehensive technical analysis solution.
MTF Fusion - S/R Trendlines [TradingIndicators]MTF Fusion S/R Trendlines intelligently adapt to whatever timeframe you're trading - dynamically calculating support and resistance trendline levels combined from four appropriate higher timeframes to give you a much broader view of the market and an edge in your trading decisions.
These trendlines are not programmed to repaint - so you can use them in real-time just as they appeared historically.
What is MTF Fusion?
Multi-Timeframe (MTF) Fusion is the process of combining calculations from multiple timeframes higher than the chart's into one 'fused' value or indicator. It is based on the idea that integrating data from higher timeframes can help us to better identify short-term trading opportunities within the context of long-term market trends.
How does it work?
Let's use the context of this indicator, which calculates S/R Trendlines, as an example to explain how MTF Fusion works and how you can perform it yourself.
Step 1: Selecting Higher Timeframes
The first step is to determine the appropriate higher timeframes to use for the fusion calculation. These timeframes should typically be chosen based on their ability to provide meaningful price levels and action which actively affect the price action of the smaller timeframe you're focused on. For example, if you are trading the 5 minute chart, you might select the 15 minute, 30 minute, and hourly timeframe as the higher timeframes you want to fuse in order to give you a more holistic view of the trends and action affecting you on the 5 minute. In this indicator, four higher timeframes are automatically selected depending on the timeframe of the chart it is applied to.
Step 2: Gathering Data and Calculations
Once the higher timeframes are identified, the next step is to calculate the data from these higher timeframes that will be used to calculate your fused values. In this indicator, for example, the values of support and resistance trendlines are calculated for all four higher timeframes.
Step 3: Fusing the Values From Higher Timeframes
The next step is to actually combine the values from these higher timeframes to obtain your 'fused' indicator values. The simplest approach to this is to simply average them. If you have calculated the value of a support trendline from three higher timeframes, you can, for example, calculate your 'multi-timeframe fused trendline' as (HigherTF_Support_Trendline_1 + HigherTF_Support_Trendline_2 + HigherTF_Support_Trendline_3) / 3.0.
Step 4: Visualization and Interpretation
Once the calculations are complete, the resulting fused indicator values are plotted on the chart. These values reflect the fusion of data from the multiple higher timeframes, giving a broader perspective on the market's behavior and potentially valuable insights without the need to manually consider values from each higher timeframe yourself.
What makes this script unique? Why is it closed source?
While the process described above is fairly unique and sounds simple, the truly important key lies in determining which higher timeframes to fuse together, and how to weight their values when calculating the fused end result in such a way that best leverages their relationship for useful TA.
This MTF Fusion indicator employs a smart, adaptive algorithm which automatically selects appropriate higher timeframes to use in fusion calculations depending on the timeframe of the chart it is applied to. It also uses a dynamic algorithm to adjust and weight the lookbacks used for trendline calculations depending on each higher timeframe's relationship to the chart timeframe. These algorithms are based on extensive testing and are the reason behind this script's closed source status.
Included Features
Fusion Support and Resistance Trendlines
Dynamic Multi-Timeframe Trendlines
Breakaway Zone fills to highlight breakouts and breakdowns from the Fusion trendlines
Customizable lookback approach
Pre-built color stylings
Options
Fusion View: Show/hide the Fusion trendlines calculated from multiple higher timeframes
MTF View: Show/hide the trendlines from multiple higher timeframes used to calculate the Fusion trendlines
Breakaway Zones: Show/hide the fill for zones where price breaks away from the Fusion trendlines
Lookback: Select how you want your trendlines to be calculated (longer = long-term trendlines, shorter = short-term trendlines)
Pre-Built Color Styles: Use a pre-built color styling (uncheck to use your own colors)
Manual Color Styles: When pre-built color styles are disabled, use these color inputs to define your own
Bounce Manager 20 TrendlinesThe trendline script is made for manual input of trendlines using point clicks on the chart. The script will then see if price respects these lines by the parameters you input in settings panel. On a respectable bounce it will print buy/sell arrows. The script also has functionality to send alerts, this is helpful if you want to automate trendlines. I created this script and many others under the bounce manager toolkit to expand on the signalling capabilities of popular drawing tools as I find using just a crossover to be lacking especialy for full automation.
components:
- Line respect: When price moves past this the script will no longer look for entry until a new trend has been established. The line can also be used as a stop loss.
- Confirmation: When price touches the line during a trend it
will wait to cross over this line to confirm a reaction from the line.
- Consolidation filter: A trend filtering system, this is a distance from
the line price has to break to confirm trend direction.
- Stop loss: This can be set to a percentage distance from the low after
bounce. Or it can be set to the line respect line
- Take profit: This can be a fixed take profit target or a risk to reward
based take profit. With risk to reward it will multiply the stop loss
distance by the input and use that to create target (green cross)
- ATR based or % based: there are 2 versions of the script, one for strict
percentage based logic and another one based on ATR values
If you are having problems figuring out which settings to use I recommend you check the Bounce Manager ATR script for reference as this script plots the components:
Zignaly automation settings:
zignaly integration, you can use the settings panel to decide your risk management. Option to use a fixed take profit % or an automatic risk to reward calculation based on the stop loss. Stop loss can get calculated using the max violation setting as a stop loss (this will put stop loss below line respect level) or when not checked it will use 0.01% below the low of the signal candle as stop loss. Just add your zignaly private key in the settings and use any alert function call as alert. Make sure to use zignaly.com as your webhook url.
The trendlines you see in preview are based on a long term pitchfork on BTCUSDT 10H chart
If 20 trendlines are too much I will be releasing a 5 line input version, this script is more to be used to automate pitchforks, gann boxes etc.
Part of the Honest Algo indicator suite
[UPRIGHT Trading] Auto-Trendlines Pro (cc)Hello Traders -
Today I am releasing a full-featured auto-trendline indicator.
This makes it easier for beginners and professionals alike to analyze a charts trending support and resistance.
What are Trendlines and why do we use them?
In short, a trendline is a diagonal line that connects to two or more price points on a chart to show the current direction of price. These are used to identify and confirm trend direction in technical analysis and show support and resistance points.
Utilizing pivot points and different calculations for sources we're able to create the trendlines; with adjustable slopes (or just use of proprietary calculations) we are able to make these lines to line up with the current trend.
How it's different:
Accurate auto-drawn calculated trendlines.
Fully customizable - the ability to adjust the trendlines easily to exact specifications with every type of trader in mind.
Can be used to spot long trend as well as short, by adjusting length or using extend both to see previous pivots it's touched.
Then retracted, for perfect long trend.
Can show old trendlines for analysis (click image to see).
Auto-labels Higher-Highs, Higher-Lows, Lower-Highs, Lower-Lows at pivots.
Lining up trendlines with Break signals can help provide more accurate trendlines (potentially teaching) beginners how to draw them better.
Signature double trendline set.
Also notice the additional sell/buy signals (shown above).
Squeeze / Low-float mode adjusts to fit big moves.
Adjust the opacity to hide or fade a line (as seen above).
Pre-filled alerts for breakouts / breakdowns.
Please see author instructions for access.
Cheers,
Mike
(UPRIGHT Trading)
Stochastic Trendlines with Breakouts [Jamshid] - EnhancedStochastic Trendlines with Breakouts - Enhanced Version
This advanced Stochastic Trendlines with Breakouts script combines several powerful features to provide enhanced breakout detection based on the Stochastic Oscillator and additional confirmation signals. This script is designed to help traders identify key trend reversals, breakout points, and pivot levels with more accuracy by integrating advanced filters such as RSI confirmation, moving average trend filtering, volatility filtering, divergence detection, and multi-timeframe analysis.
Key Features:
Stochastic Oscillator-Based Breakouts:
Automatically detects breakouts based on the smoothed Stochastic Oscillator values (%K and %D), providing insights into overbought and oversold conditions.
Customizable overbought and oversold levels, with a mid-level (50) line for additional reference.
Trendlines on Pivot Points:
Automatically plots dynamic trendlines based on pivot highs and lows of the smoothed Stochastic %K, helping to visualize potential reversal points.
RSI Confirmation (Optional):
Filters breakout signals using the Relative Strength Index (RSI) to confirm breakouts only when the RSI is below 50 for downtrend breakouts and above 50 for uptrend breakouts.
Visual confirmation with a green "RSI Conf." label displayed on the chart when the RSI condition is met.
Moving Average Filter (Optional):
Confirms breakout signals in the direction of a user-defined Moving Average (MA) to trade in the overall market trend direction.
MA length is fully customizable.
Stochastic Divergence Filter (Optional):
Detects bullish or bearish divergence between the price and Stochastic Oscillator values, adding an extra layer of confirmation.
Multi-Timeframe Confirmation (Optional):
Confirms breakouts by checking the Stochastic %K and %D values from a higher timeframe. This helps in avoiding false signals by aligning with the broader market trend.
The higher timeframe can be customized to any timeframe (e.g., daily, weekly, etc.).
Volatility Filter (Optional):
Uses the ATR (Average True Range) to filter out breakouts during periods of low volatility, ensuring signals are only triggered when there is sufficient price movement.
ATR length and multiplier are fully customizable.
Custom Alerts:
Alerts are available for new trendline detections (both pivot high and pivot low) and for confirmed breakout signals. These alerts help traders stay informed in real-time without needing to monitor the chart continuously.
How to Use:
Customize the Stochastic Oscillator settings, such as %K smoothing and %D line parameters, to fit your trading strategy.
Enable or disable additional filtering features (RSI, MA, divergence, MTF, volatility) as needed.
Set up alerts for specific breakout conditions directly in TradingView to stay notified when breakout signals are triggered.
This script is designed for traders who are looking for precision breakout signals with added layers of confirmation to avoid false breakouts and enhance trading accuracy.
RSI with Divergences and Trendlines by zenDisplays the standard Relative Strength Index (RSI). The RSI period, line color, and thickness are customizable by the user (defaulting to a 14-period, thin black line).
Includes traditional horizontal lines at the 70 (overbought) and 30 (oversold) levels. The background area between these levels is filled with a customizable color (defaulting to a transparent black).
The indicator intelligently analyzes the RSI's own movements to identify significant recent turning points (peaks and troughs).
It then automatically draws short trendline segments directly on the RSI chart. These lines connect recent, consecutive RSI turning points, dynamically highlighting the indicator's internal structure and immediate directional momentum.
Users can configure the sensitivity used to detect these RSI turning points via 'Pivot Lookback' settings. You can also customize the maximum number of recent trendlines displayed for upward and downward RSI movements (default is 5 each), as well as their colors and width.
These on-RSI trendlines do not extend into the future.
Machine Learning Trendlines Cluster [LuxAlgo]The ML Trendlines Cluster indicator allows traders to automatically identify trendlines using a machine learning algorithm based on k-means clustering and linear regression, highlighting trendlines from clustered prices.
For trader's convenience, trendlines can be filtered based on their slope, allowing them to filter out trendlines that are too horizontal, or instead keep them depending on the user-selected settings.
🔶 USAGE
Traders only need to set the number of trendlines (clusters) they want the tool to detect and the algorithm will do the rest.
By default the tool is set to detect 4 clusters over the last 500 bars, in the image above it is set to detect 10 clusters over the same period.
This approach only focuses on drawing trendlines from prices that share a common trading range, offering a unique perspective to traditional trendlines. Trendlines with a significant slope can highlight higher dispersion within its cluster.
🔹 Trendline Slope Filtering
Traders can filter trendlines by their slope to display only steep or flat trendlines relative to a user-defined threshold.
The image above shows the three different configurations of this feature:
Filtering disabled
Filter slopes above threshold
Filter slopes below threshold
🔶 DETAILS
K-means clustering is a popular machine-learning algorithm that finds observations in a data set that are similar to each other and places them in a group.
The process starts by randomly assigning each data point to an initial group and calculating the centroid for each. A centroid is the center of the group. K-means clustering forms the groups in such a way that the variances between the data points and the centroid of the cluster are minimized.
The trendlines are displayed according to the linear regression function calculated for each cluster.
🔶 SETTINGS
Window Size: Maximum number of bars to get data from
Clusters: Maximum number of clusters (trendlines) to detect
🔹 Optimization
Maximum Iteration Steps: Maximum loop iterations for cluster computation
🔹 Slope Filter
Threshold Multiplier: Multiplier applied to a volatility measure, higher multiplier equals higher threshold
Filter Slopes: Enable/Disable Trendline Slope Filtering, select to filter trendlines with slopes ABOVE or BELOW the threshold
🔹 Style
Upper Zone: Color to display in the top zone
Lower Zone: Color to display in the bottom zone
Lines: Style for the lines
Size: Line size
Auto Trendlines [RG]Auto Trendlines
Overview
Auto Trendlines automatically identifies, draws, and manages dynamic support and resistance trendlines based on pivot points. It continuously monitors price action to validate and update trendlines.
Key Features
Automatically identifies support (green) and resistance (red) trendlines
Validates trendlines against historical price action
Configurable lookback period and maximum active lines
Clean visualization with customizable line widths
How It Works
The indicator detects pivot highs and lows using your specified lookback period
It connects consecutive pivots to create potential trendlines
Lines are extended to the right until a confirmed price break
Older lines are automatically removed when the maximum is reached
Customization Options
Lookback Period: Controls the sensitivity of pivot detection
Maximum Active Lines: Limits the number of trendlines displayed
Line Width: Separate width controls for support and resistance lines
Ideal For
Identifying dynamic support and resistance levels.
Spotting potential reversal zones.
This indicator will help you identify trendlines, which you can then sophisticate and redraw more accurately. Please use this indicator only to identify trendline scenarios. Keep in mind that this is not a buy and sell indicator. Trendline breaks and bounces are not always respected, as prices can turn around at any moment. Happy Trading :)
[TC] -- DayTrader's Auto Ultra TrendlinesThe goal of this indicator is to provide day traders with more realistic and general support and resistance trendlines for the chart timeframe they are trading, without the need for excessive parameter adjustment or manual consideration of trendlines from higher timeframes. As we all know, when trading smaller timeframes, it is not only the trendlines from the current timeframe which are significant - we must also consider the position of trendlines from higher ones.
Auto Ultra Trendlines plots a set of multi-timeframe-based resistance and support trendlines that are dynamically calculated depending on the timeframe of the chart which the indicator is applied to.
The indicator calculates conglomerated support and resistance trendlines based on trendline values calculated from several timeframes higher than the chart's. The higher timeframes are logically selected and differ based on the chart timeframe.
This indicator is designed to be applied to charts with a timeframe up to and including the 8H, and cannot be applied to charts with a timeframe greater than 1D.
To increase or decrease the lookback period for the trendlines, use the 'Lookback Factor' parameter.
BOSS Automatic Trendlines and Support Zones IndicatorTHE BEST FOREX, BINARY OPTIONS, STOCK AND CRYPTO INDICATORS FOR TRADINGVIEW.COM
Our auto-trendlines indicator and our support and resistance zones indicator with Fast and Slow EMA's all combined in one!
TrendLines
Trendlines when drawn properly make an excellent tool for traders. Used improperly though, they become ineffective and even counterproductive, resulting in a belief that prices have made a reversal when they really haven't, or that a trend has strength when price action suggests it doesn't.
The Boss Auto Trendline Indicator draws the trendlines automatically, and now you can effectively use trendlines as part of your trading strategy.
Trendlines highlight a trend or range (sideways movement). A trendline connects swing lows, where the low is lower than the surrounding prices, and swing highs in price. When the price rises, the swing lows rise.
Red Lines & Dots.
Connecting these lows with a line results in an ascending trendline , showing you that the trend is up. A trendline can also be drawn along the swing highs. This shows the angle of ascent, and the strength of the price move, whether strongly higher or not.
Green Lines & Dots
When the price falls, the swing highs fall. Connecting these highs with a line results in a descending trendline , illustrating the downward trend. A trendline can also be drawn along the swing lows. This shows the angle of descent and the strength of the downward price movement.
Support & Resistance Zones
Green = Support Zones
Red = Resistance Zones
The basic trading method for using support and resistance is to buy/long near support in uptrends, and to sell/short near resistance in downtrends.
Fast & Slow EMA's
Trend Following - you essentially use the EMA to track the primary trend. If a trading pair does not close beyond the average - you stay in the trade.
Moving Average Crosses - by using two different exponential moving average crosses you can generate buy and/or sell signals. For example, you can have a fast average cross a slow average to trigger a trade signal.
Dynamic Support and Resistance - EMA periods like the 21 or 55 can act as support and resistance zones.
Dynamic Trendlines Multi-TimeframeThe Dynamic Trendlines indicator is a useful tool for traders to identify potential support and resistance levels in the market. By analyzing price volatility and drawing trendlines based on high volatility candles, it helps traders visualize key price levels that may influence future price action. This indicator uses the Average True Range (ATR) as a measure of price volatility to determine the threshold for high volatility candles. This indicator can be used on multiple time frames, so just choose which one works best for you!
The underlying concept of this indicator revolves around the calculation of the True Range and Average True Range. The True Range is the maximum value among the difference between the current high and low, the absolute value of the difference between the current high and previous close, and the absolute value of the difference between the current low and previous close. The ATR is then calculated as the simple moving average of the True Range over a user-defined period (default is 14). The threshold for high volatility candles is determined by multiplying the ATR by a user-defined multiplier (default is 1.5).
The indicator identifies high volatility candles when the closing price is greater than the previous closing price plus the threshold. Based on the price action, trendlines are drawn connecting the high or low of high volatility candles. The initial color and style of the trendline are determined by whether the price is moving up or down. Green solid lines represent upward price movement, while red solid lines represent downward price movement.
As the price crosses the trendlines, the indicator tracks the number of crosses and updates the line's style accordingly. If the price crosses a trendline twice, the line style is changed to dashed, indicating the potential weakening of the support or resistance level.
This indicator works best with trading methods that focus on capturing price breakouts or reversals. Traders can use the trendlines to identify potential entry or exit points, stop-loss levels, or take-profit targets. It's important to note that this indicator should be used in conjunction with other technical analysis tools and an understanding of the overall market context to make informed trading decisions.
When using the Dynamic Trendlines indicator on TradingView, users can customize the ATR length, threshold multiplier, and the number of recent trendlines displayed on the chart. Additionally, small triangles are plotted below high volatility candles, with their color based on the trendline it starts, providing a quick visual reference for traders.
In summary, the Dynamic Trendlines indicator is a valuable tool for identifying potential support and resistance levels in the market by analyzing price volatility and drawing trendlines based on high volatility candles. It is best suited for breakout and reversal trading strategies and should be used in conjunction with other technical analysis tools for optimal results.
BOSS Automatic TrendlinesTHE BEST FOREX, BINARY OPTIONS, AND CRYPTO INDICATORS FOR TRADINGVIEW.COM
Trendlines when drawn properly make an excellent tool for traders. Used improperly though, they become ineffective and even counterproductive, resulting in a belief that prices have made a reversal when they really haven't, or that a trend has strength when price action suggests it doesn't.
The Boss Auto Trendline Indicator draws the trendlines automatically, and now you can effectively use trendlines as part of your trading strategy.
Trendlines highlight a trend or range (sideways movement). A trendline connects swing lows, where the low is lower than the surrounding prices, and swing highs in price. When the price rises, the swing lows rise.
Red Lines & Dots.
Connecting these lows with a line results in an ascending trendline, showing you that the trend is up. A trendline can also be drawn along the swing highs. This shows the angle of ascent, and the strength of the price move, whether strongly higher or not.
Green Lines & Dots
When the price falls, the swing highs fall. Connecting these highs with a line results in a descending trendline, illustrating the downward trend. A trendline can also be drawn along the swing lows. This shows the angle of descent and the strength of the downward price movement.
Available at bosscripts.com
Website bosscripts.com
Breakout of inclined trendline [Drobode]█ DESCRIPTION
The script is designed to automatically detect a possible trendline breakout under the conditions of the popular "Slanted Trendline Breakout" strategy. The algorithm assumes that during the movement the price approaches the slanted (trend) line several times. With each subsequent approach (touch) to the trend line, the price consolidates more and more near this line, the distances between the extremes (touches) decrease, which indicates a high probability of a breakout of this line. The script checks the number of touches (approaches) of the extremes and the distances between the extremes. If all conditions are met, the script draws a slanted (trend) line in the corresponding area and an arrow with a possible price breakout direction. The length of the arrow is half the height of the slanted (trend) line and may indicate the level (price) at which it is advisable to fix the profit. In the script, you can enable or disable additional analysis periods (history length, number of bars), the more periods are enabled, the slower the script may load. For example, when placing the script on M-15, we can additionally enable the period 300 or 500, which will allow us to take into account a larger number of historical bars, and this can be considered as the extremes of the older timeframe. The script calculates each period separately, so one large period will not be able to take into account and analyze smaller periods. You can set the percentage deviation of the distance of the extremes from the trend line that touch the inclined line, depending on your needs and style of technical analysis. The smaller the percentage, the more accurate and closer to the inclined line the price extreme should be and vice versa. The main goal of the script is to facilitate the trader's routine work of identifying a possible trend line breakout. However, it should be understood that the script is not a full-fledged self-sufficient strategy, in case of receiving a signal, it is recommended to additionally conduct a comprehensive thorough analysis before taking trading actions. The script can be useful for traders of all levels, both beginners and experienced analysts. Like any other strategy or script, this script can work better on some instruments than on others. When analyzing trading setups, it is desirable to have a clear trend, it is recommended to take into account the signal of this script with a small period when the arrow shows the direction of the trend. However, at the same time, it is necessary to deeply analyze many other factors at this stage, in particular, such as volumes, consolidation, volatility, candlestick patterns, etc.
█ SCRIPT SETTINGS
By default, the script was developed and tested on medium timeframes with cryptocurrency futures instruments USDT.P
Alert
The Alert function in the script is enabled by default, you just need to activate Alert in the TradingView window and select the signal source - Breakout of inclined trendline .
The notification provides the following information (example):
Possible breakout to the upside
Ticker- DOGEUSDT.P
Price- 0.15844
Timeframe- 30
Period length- 377
Periods length
The script allows you to set the length of the period (number of bars) for which the calculation will be performed. Different periods allow you to cover more timeframes (in particular, larger timeframes). You can change up to 4 periods at a time. However, if you choose too large periods, the script may slow down and the loading time will increase. To increase the loading speed of the script, disable additional periods 3, 4, i.e. uncheck the corresponding checkboxes and use only fields 1 and 2 for periods, where you can also set the period length you need.
Percentage deviation of extremes from the trend line
The next settings are the percentage deviation of the extremes from the sloping line. The smaller the deviation, the more accurate and closer to the line the extreme bars should be, however, in this case the number of identification signals will be smaller. By default, the rejection zone is - 0.15%. On larger timeframes, the deviation can be set to be larger.
RSI Trendlines with BreakoutsA pivot-based breakout indicator that attempts to provide traders with a visual aid for finding breakouts on the RSI. Similar to how we use trendlines on our charts, using them on the Relative Strength Index can also give us a sense of direction in the markets.
This script uses its own pivot-based system that checks for real-time swing levels and triggers a new pivot event after every dip and nth bars. The breakout alerts that are given were not designed to be taken as signals since their purpose is to provide an extra bit of confluence. Because of this, I added no other conditions that try to make the alerts "perfect", but instead, print every breakout that is detected. Despite stating this, I did happen to add a condition that checks the difference in RSI and the breakout value, but that's as far as it'll go.
There are alerts built-in to the script, along with adjustable repainting options.
🔳 Settings
Lookback Range: Lookback period to trigger a new pivot point when conditions are met.
RSI Difference: The difference between the current RSI value and the breakout value. How much higher in value should the current RSI be compared to the breakout value in order to detect a breakout?
RSI Settings
Styling Options
🔳 Repaint Options
On: Allows repainting
Off - Bar Confirmation: Prevents repainting and generates alerts when the bar closes. (1 candle later)
🔳 How it Works
Before a trendline is drawn, the script retrieves the slope between the previous pivot point and the current. Then it adds or subtracts the slope x amount of times (based on the lookback range) from the current pivot value until the current x-axis is reached. By doing this we can get a trendline that will detect a breakout accurately.
The result
When using the RSI Difference condition, the script will print breakouts whenever the condition is true, because of this dotted lines were added to track where the alert was triggered.
🔳 Alerts
Liquidity Trendline With Signals [BigBeluga]The Liquidity Trendline is an indicator designed to identify potential breakouts by utilizing pivot points. These pivotal moments can trigger significant market reactions, either by breaking out or by serving as breakout and retest signals.
🔶 FEATURES
The indicator contains the following features:
Period of the calculation
Padding (spacing between the 2 lines)
Signal for breakouts
🔶 USAGE
As shown in the example, breakouts can be powerful points to see reversions in the market and can lead to a lot of volatility in the market.
When a trendline is broken, a signal will be plotted; the user can disable/enable those signals.
A trendline is formed when 2 consecutive pivot points are found, each of them lower or higher than the previous one. this is the anchor point for our trend line that we will use to spot rejection or breakouts
The delay in the creation of those trend lines will be the period input used to find the pivot point on the chart.
Another good example is using these trendlines as simple retests.
Prices bouncing on top of them will suggest a possible continuation of the current trend.
We can filter out stronger breakouts by looking at how many times the price has rejected the trendline, more rejections will result in more liquidity once the price breaks it.
Signals are plotted on the chart for every breakout that happens.
Another good utility is simply using them as retest once the price breaks those levels and holding above/below them, indicating a possible support or resistance area used for confluence
Here is another good example of how we can correctly spot price deviating from our trendline and spotting powerful continuation in price.
As said before we can filter out bad and good breakouts simply by looking at how many times rejected from those levels.
More rejection will result in a stronger reaction
🔶 CONCLUSION
This script is as simple as that and can be used in a few ways to spot reversals, price continuation, or even sentiment in price (bullish or bearish).
Pivot Trendlines with Breaks [HG]🧾 Pivot Trendlines and Breaks
A script meant to debut and provide an example usage of the Simple Trendlines library using Pine Script's built-in pivot system.
In under 50 lines of code, with inputs, plots, styling, and alerts included we're able to create trendlines with a breakout system.
▶️ How it works
Calculating pivot points helps traders identify moments at which the market's attitude can shift from bullish to bearish. In the background, the script tracks pivot events for trendlines and uses a system that prevents any leakage between the trendlines before they are drawn.
⚫️ Settings
Pivot Length
Color Adjustments
⚫️ Alerts
RSI Trendlines [RG]Overview
RSI Trendlines combines the power of automatic trendline detection with the popular Relative Strength Index (RSI) indicator. This tool identifies and plots dynamic support and resistance trendlines directly on the RSI chart, helping you spot potential trend changes and divergences in momentum before they appear in price.
Key Features
Automatically detects and draws trendlines on the RSI indicator
Identifies significant pivot points in RSI momentum
Customizable appearance with adjustable colors and line widths
Built-in alerts for trendline breaks
How It Works
The indicator calculates the standard RSI using your preferred settings
It identifies pivot highs and lows in the RSI using the specified lookback period
Valid trendlines are drawn connecting consecutive pivots
Lines extend until they experience a confirmed break
Customization Options
RSI Parameters: Adjust length and source to your preference
Trendline Settings: Control pivot detection sensitivity and maximum lines
Visual Options: Customize colors, line widths, and optional midline display
Ideal For
Identifying established trends in momentum
Spotting potential RSI divergences early
Timing entries and exits based on momentum shifts
Confirming trend changes with objective trendline breaks
This indicator aims to help traders move beyond static overbought/oversold levels by revealing the dynamic structure of momentum trends and highlighting potential reversals and continuations.
Please don't use this as a buy and sell indicator. Use it to get an idea on the market trend and as an extra confirmation for your trades. Happy Trading :)
Bounce Manager TrendlinesThe trendline script is made for manual input of trendlines using point clicks on the chart. The script will then see if price respects these lines by the parameters you input in settings panel. On a respectable bounce it will print buy/sell arrows. The script also has functionality to send alerts, this is helpful if you want to automate trendlines . I created this script and many others under the bounce manager toolkit to expand on the signalling capabilities of popular drawing tools as I find using just a crossover to be lacking especialy for full automation.
components:
- Line respect: When price moves past this the script will no longer look for entry until a new trend has been established. The line can also be used as a stop loss.
- Confirmation: When price touches the line during a trend it
will wait to cross over this line to confirm a reaction from the line.
- Consolidation filter: A trend filtering system, this is a distance from
the line price has to break to confirm trend direction.
- Stop loss: This can be set to a percentage distance from the low after
bounce. Or it can be set to the line respect line
- Take profit: This can be a fixed take profit target or a risk to reward
based take profit. With risk to reward it will multiply the stop loss
distance by the input and use that to create target (green cross)
- ATR based or % based: there are 2 versions of the script, one for strict
percentage based logic and another one based on ATR values
If you are having problems figuring out which settings to use I recommend you check the Bounce Manager ATR script for reference as this script plots the components:
Zignaly automation settings:
zignaly integration, you can use the settings panel to decide your risk management. Option to use a fixed take profit % or an automatic risk to reward calculation based on the stop loss. Stop loss can get calculated using the max violation setting as a stop loss (this will put stop loss below line respect level) or when not checked it will use 0.01% below the low of the signal candle as stop loss. Just add your zignaly private key in the settings and use any alert function call as alert. Make sure to use zignaly.com as your webhook url.
If 5 trendlines are not enough use the 20 line input version, this script is for the clean strong trendline trader.
Part of the Honest Algo indicator suite
Auto Bull/Bear TrendlinesAutomated trendlines for easily identifying market trend continuation or reversals