OPEN-SOURCE SCRIPT
Trendline Indicator for Pionex 2

//version=5
indicator("Trendline Indicator for Pionex", overlay=true)
// ----- קו מגמה ידני -----
// יוצרים קו מגמה פשוט לגרירה ידנית
var line trendLine = line.new(x1=bar_index-10, y1=close[10], x2=bar_index, y2=close, extend=extend.right, color=color.blue, width=2)
// קבלת המחיר הנוכחי של הקו
trendPrice = line.get_price(trendLine, bar_index)
// ----- תנאי קנייה ומכירה -----
longCondition = close > trendPrice
shortCondition = close < trendPrice
// ----- הצגה גרפית של תנאי הקנייה והמכירה -----
plotshape(longCondition, style=shape.triangleup, location=location.belowbar, color=color.green, size=size.small)
plotshape(shortCondition, style=shape.triangledown, location=location.abovebar, color=color.red, size=size.small)
indicator("Trendline Indicator for Pionex", overlay=true)
// ----- קו מגמה ידני -----
// יוצרים קו מגמה פשוט לגרירה ידנית
var line trendLine = line.new(x1=bar_index-10, y1=close[10], x2=bar_index, y2=close, extend=extend.right, color=color.blue, width=2)
// קבלת המחיר הנוכחי של הקו
trendPrice = line.get_price(trendLine, bar_index)
// ----- תנאי קנייה ומכירה -----
longCondition = close > trendPrice
shortCondition = close < trendPrice
// ----- הצגה גרפית של תנאי הקנייה והמכירה -----
plotshape(longCondition, style=shape.triangleup, location=location.belowbar, color=color.green, size=size.small)
plotshape(shortCondition, style=shape.triangledown, location=location.abovebar, color=color.red, size=size.small)
Script de código abierto
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Exención de responsabilidad
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Script de código abierto
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Exención de responsabilidad
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.