Watchlist columns are not updating

Sathiesh

New member
Hello,

I have a custom watchlist column (Custom 7) created based on the SMA (code as below), however its value is static and does not update as per the realtime data. The same code as a study renders fine on a chart (the red line on the lower section chart - simple_ma_cross). Can somebody help me with this ?

Code:
def shortMA = simpleMovingAvg(Length = 9);
def longMA = simpleMovingAvg(Length = 20);

plot Scan = longMA is greater than shortMA;


C4LTpvV.png
 
I think I figured that out, now the values are changing, but the values are not changing accurately... When I right click and edit a column, what is the difference between offset and within n bars condition ?
 
I think I figured that out, now the values are changing, but the values are not changing accurately... When I right click and edit a column, what is the difference between offset and within n bars condition ?
Offset within Study code has to do with which single candle/bar prices to use... Within ## bars determines the lookback range for potentially meeting your scan criteria...
 
@rad14733 Thanks for your clarifications.

My watchlist columns are not refreshing the same way as the chart. I am using the same code/formula in the chart and columns, but the column values are not changing as dynamically as they're changing on the chart. Moreover, on the custom columns, when i remove "within n bars" from the formula and simply select "as value", the data remain static and doesn't change at all.

I'm finding it a bit hard to understand these different behaviors for the very same code. Can you please help explain this?
 
@rad14733 Thanks for your clarifications.

My watchlist columns are not refreshing the same way as the chart. I am using the same code/formula in the chart and columns, but the column values are not changing as dynamically as they're changing on the chart. Moreover, on the custom columns, when i remove "within n bars" from the formula and simply select "as value", the data remain static and doesn't change at all.

I'm finding it a bit hard to understand these different behaviors for the very same code. Can you please help explain this?
You obviously haven't stumbled across any of the numerous posts that reference the fact that Watchlists don't update in real-time like charts do, or at least as real-time as it gets... Watchlist Custom Columns only update every 3 - 5 minutes, not real-time... There is an update hierarchy within the platform, although not officially documented to the best of my knowledge, with Charts and standard Watchlist Columns updating the closest to real-time... I'm not even sure where Conditional Orders fall within the hierarchy but those are triggered from the servers anyway, not from the TOS platform... Custom Columns and Scans take a bit longer and during high demand times they can lag significantly... Hope this helps...
 
@rad14733 But i see the column values never changing at all. Not after 3 mins, not after 5 mins - if I remove the "within n bars" and select as value for the column. I have tried different strategies and I see different behavior with different strategies. Does using a future offset in a column work ? or can that be a cause to the behavior I see ?
 

Join useThinkScript to post your question to a community of 21,000+ developers and traders.

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
274 Online
Create Post

Similar threads

Similar threads

The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
  • Exclusive indicators
  • Proven strategies & setups
  • Private Discord community
  • ‘Buy The Dip’ signal alerts
  • Exclusive members-only content
  • Add-ons and resources
  • 1 full year of unlimited support

Frequently Asked Questions

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?
VIP members get exclusive access to these proven and tested premium indicators: Buy the Dip, Advanced Market Moves 2.0, Take Profit, and Volatility Trading Range. In addition, VIP members get access to over 50 VIP-only custom indicators, add-ons, and strategies, private VIP-only forums, private Discord channel to discuss trades and strategies in real-time, customer support, trade alerts, and much more. Learn all about VIP membership here.
How can I access the premium indicators?
To access the premium indicators, which are plug and play ready, sign up for VIP membership here.
Back
Top