Category "pine-script-v4"

Pine Script Strategy - Position Entry directly after Exit

i want to do a strategy that entries a position at the buy-level (blue Line) and sells after reaching the take-profit-Level (green line) or the stop-level (red

How to implement a Super trend crossover

I am new to pine script. I am trying to create strategy with below condition. if current price is greater than supertrend(5,1) and current price is greater than

Pinescript - Why does my stoploss trigger upon entry stop?

I'm working strategy based on a MTF Stoch RSI indicator I created. In the strategy, based on Stoch RSI higher and medium timeframe direction and entry timeframe

Get Value of MACD on different TimeFrame

How can you get the value of the Macd Line and Signal Line real-time from different timeframe. Like for example I am on a 4HR chart and I want to get the value

Check if crossover occurred in the period of last 10 candles

I am working on a strategy that requires me to check if there was a certain crossover few candles back in time when I get my signal on current candle close. Rig

plotting Candles as Seconds Timefame/ Chart(TradingView/Pinescript)

is there a way to plot candles as Seconds Timeframe, without using a timeframe.isseconds. found a calculation but i cant plot candle on it. // calculate bar tim