Top % in last trailing 30 minutes (updating every 1 minute)

evanevans

Active member
I was wondering if anyone knows of any existing code/indicators which would show the top ten Percent% Gainers (all stocks, tick_count>1000) in the last 30 minutes, updating every minute (so something like close>close[30] on a 1m(ext), that will cover all of pre, market, and post market hours? I can tinker with code, so anything close I can probably work with. Any help much appreciated. (yes I did several searches but it didn't prove very fruitful for me). Many thanks in advance!
 
Solution
The first step is to create a custom watch list column. Then you set your scan to be "Sorted By:" the custom column descending. A scan set to "Show:" ten stocks will provide you with a top ten list, or what ever number you choose. The settings will be primarily dictated by the column's own settings, that's where you would select the time frame, extended hours, and so on. The scan itself can even be left blank, unless you have other criteria.

I can't determine the time frame of the desired 1000 ticks based on how you worded it.
This would be for a 30 minute column:
Code:
plot Column = if tick_count >= 1000
then (close - close[1]) / close[1] * 100
else Double.NEGATIVE_INFINITY;

There is no way to control how often a scan will...
The first step is to create a custom watch list column. Then you set your scan to be "Sorted By:" the custom column descending. A scan set to "Show:" ten stocks will provide you with a top ten list, or what ever number you choose. The settings will be primarily dictated by the column's own settings, that's where you would select the time frame, extended hours, and so on. The scan itself can even be left blank, unless you have other criteria.

I can't determine the time frame of the desired 1000 ticks based on how you worded it.
This would be for a 30 minute column:
Code:
plot Column = if tick_count >= 1000
then (close - close[1]) / close[1] * 100
else Double.NEGATIVE_INFINITY;

There is no way to control how often a scan will auto-update. It's usually around five minutes +/- a couple of minutes. If you add the column to the scan's results, and anything shows up as -infinity, then currently there are not enough stocks with 1000 tick count. This feature of the scanner can be janky during any sort of maintenance, weekends.
 
Solution

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