Calculated ATR Levels in Script Are Different On Chart and Alert on the Same Script
I’m writing a custom indicator script extending the “LuxAlgo – Predictive Ranges” indicator. However, I’ve noticed a strange thing.
My Pinescript strategy is closing trades immediatly after opening and i cannot understand why
doing my best to learn pinescript. im currently working with a Market Structure shift Strategy and CANNOT understan why these trades are closing immediatly after placing them.
at this stage i simply want to take trades in the direction of the identified MSS and close them on an opposing one.
Strategy script is running with no errors but I get no trades
I am having trouble with my strategy script. I am using an ATR and a hull moving average to determine my entry and exit conditions. However, when I run the code, it runs with no error but I dont see any trades executed based off of the specific conditions. Am I doing something wrong with my code?
Retrieve historical candle data by dayofweek and specific time
I try to build an indicator to get the ranges of candles by the same day of week, hour and minute, then to compare the current candle range with the average.
I use last_bar_time to get the bar time of last candle displayed by the chart.
When the engine loops through bar_indexes from 0 till the end, if the dayofweek, hour and time are matched with last_bar_time details, store the values in an array.
how to find highest and lowest value of ttm squeeze range
Hello im trying to find the highest and lowest value of ttm squeeze range. i tried using ta.highiest but kept getting study error. i wanted to try save it in a list, then use .sort to order it.
Pine Script Backtester Misinterprets strategy.order Scaling as Separate Trades
I’m developing a Pine Script strategy on TradingView with scaling entries positions.
While strategy.order should ideally scale into an existing position, the backtester seems to interpret each strategy.order call as a separate trade, leading to inaccurate backtesting results.
Pine Script Backtester Misinterprets strategy.order Scaling as Separate Trades
I’m developing a Pine Script strategy on TradingView with scaling entries positions.
While strategy.order should ideally scale into an existing position, the backtester seems to interpret each strategy.order call as a separate trade, leading to inaccurate backtesting results.
Cannot call operator with argument. An argument of ‘series string’ type was used but a ‘simple string’ is expected with request.security
I know this question has been asked many times, but some have got work around to this.
I am facing issue when I want to get the current price of the index and add 2 strike above or 2 strike below options value in the table to show the user which Call or Put is active, depending on the current price.
Pine script v5 – Plot/Draw previous closing prices and extend to right
I want to plot/draw a horizontal line of the previous closing price and extend to right till it is crossed. I need to extend all the closing prices which are not crossed. Time frame is any timeframe.
Pine script Date validation
I have a scenario as below in pinescript.
I provide 4 dates in user input.
Example
Input 1 – 2024-07-10
Input 2 – 2024-07-17
Input 3 – 2024-07-24
Input 4 – 2024-07-31