I wrote this code in pinescript: kijen_forw(period ) => kjf = array.new_float(20) for i = 1 to period array.set(kjf,i,donchian(kijensenPeriod
I'm trying to create a crypto trading strategy in TradingView, and everything was going well until my script decided to upgrade to v5. Everything works, but whe
Hello I isolated code which cause this strange behavior. It is caused by variable price. Is there way around? //@version=5 strategy("My script",overlay=true)
I'm building a strategy using Pine Script Version 5. I'm trying to create a stop order using strategy.order command. The command is working as expected and exec
//@version=5 indicator(title='Rsi color', shorttitle='RSI col', overlay=false) theme = input.string(defval='Dark', title='Colors', options=['Candy', 'Dark', 'L
When trying this code: strategy.risk.allow_entry_in(close > ta.vwap(hlc3) ? strategy.direction.long : strategy.direction.short) I get this error: An argume
I'm new to Pine script, please, anyone explain me exactly what this high[abs(highestbars(amplitude))] statement returns, specially in highestbars(2) definition
This is a High/Low indicator in Pine Script language. Can anyone help me to convert it into MQL4. It should be very easy for some of you https://www.tradingview
To find divergences I'm trying to get the bar_index of the first bar that has a lower low than the low of the current bar. I wish I could inject current bar va
How do i prevent orders from remaining open and executing later. For long entries i have a buystop = high, so if the next candle the price doesn't hit the high
I try to convert Strategty to study I don't know it right? if Long strategy.entry("L", strategy.long) if Short strategy.entry("S", strategy.short) I c
there is a Study to build a RELATIVE between two symbols that is like this: ` study("RELATIVE STRENGTH", shorttitle="RS") a = tickerid b = input("SPY", type=s
There you can see two horizontal (dotted white) lines on the chart below, placed manually. Is it possible to make the script retrieve their locations?
I want to apply a function to pause the strategy for xx hours or bars after win trade, how to do that? because my strategy is trending so there is always a peri
How can I put the stop loss in my strategy in tradingview to 3commas bot? I am using this code for trailing profit and stop loss strategy.entry("Short", strateg
I've been trying to create similar indicator to this This is the reference I have the code for RSI, Stochastic RSI, MACD and 50/100/200 MA (with crosses), but I
I've been trying to create similar indicator to this This is the reference I have the code for RSI, Stochastic RSI, MACD and 50/100/200 MA (with crosses), but I
I would like to convert this script from version 2 to version 4 or 5 in order to create buy and sell alert messages. Can someone help me with this or explain it
I have 3 conditions that needed for entry. But they can be met in 4 bars. I use MACD, stochastic and RSI. For example, in first bar there is macd lines cross, a
I recently started trying to code in Pine on my own and built my own OB indicator with help from some other indicators. I know want to add an alert, that is tri