TOS memory allocation and garbage cleanup

Bassindora

Member
VIP
I continue to refine the set of indicators and visualization of the results to avoid multi-collinearity. However, I am spending too much time manually moving between stocks for eval.

My first cut was to create a grid and populate it with the results of the scan. So I made a 4x4 grid. Each window is only displaying the simple chart, but the code running in the upper evaluates 9 buy/sell criteria from the indicators in the analysis window. When a threshold is hit, the background turns green for buy, red for sell, and default for the rest of the time. The code is in the attached text file, indicator eval.txt.

However, it is cumbersome to have to manually choose the stocks for each window in the grid.

I had never played with Watchlist, but decided to try to put the results of the scan there and add a column that showed the sum of the buy indicators from the code in the grid in appropriately color coded backgrounds.

This partially works. After an unknown number of stocks are displayed working correctly, the rest simply say "loading" in the column. That number is different each time. I have played around with running the scan, getting a smaller number of stocks for the watchlist, removing the scan from memory, and variations thereof ad nauseum.

The best info that I could find is that no more than ~1000 custom cells could be used at one time. But with 25 rows and one custom cell per row, I should not be close to that limit.

The grid window is not open. The only other window that is open is the analysis window. I'm not aware of any other custom cells being used.

Is there a way to find out how much memory I can access for the watchlist? Does TOS do dynamic memory garbage cleanup or do I have to close it and reopen it every time I load a new watchlist?

Any help/direction will be appreciated.

Scan: http://tos.mx/!bB7Wxf2t
Watchlist: http://tos.mx/!wCAHglnJ
Analysis window: http://tos.mx/!gApY0VG4
Grid: Grid: http://tos.mx/!Rm4IvHdo
 

Attachments

  • Analysis Window.jpg
    Analysis Window.jpg
    475.4 KB · Views: 29
  • Grid.jpg
    Grid.jpg
    468.9 KB · Views: 28
  • indicator eval.txt
    6.5 KB · Views: 8
  • Watchlist.jpg
    Watchlist.jpg
    86.5 KB · Views: 29

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
962 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