Trade Ideas 5 higher bars scanner

PotOdds

New member
Hi,
New to TD Ameritrade and ThinkScript. I was trying to replicate some real time scanning that I've used in Trade Ideas. A simple scanning filter to see stocks that have moved higher in last 5 1-min candlesticks.

Timeframe: 1 min.

plot scan = close > close[1] > close[2] > close[3] > close[4];

Is there a reason why this might not work when scanning? I've tried it on different timeframes and getting strange results. I would expect to get 5 higher bars.
 
Last edited by a moderator:
Try this?

Code:
# Generation time: 2021-04-28T04:18:25.995161600Z

def IsUp = close > open;
def IsDown = close < open;
def IsDoji = IsDoji();
def avgRange = 0.05 * Average(high - low, 20);
plot PatternPlot =
    IsUp[4] and
    IsUp[3] and
    IsUp[2] and
    IsUp[1] and
    IsUp[0] and
    close[1] < close[0] and
    close[3] < close[2] and
    close[2] < close[1] and
    close[4] < close[3];

PatternPlot.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
PatternPlot.SetDefaultColor(GetColor(0));
 
Try this?

Code:
# Generation time: 2021-04-28T04:18:25.995161600Z

def IsUp = close > open;
def IsDown = close < open;
def IsDoji = IsDoji();
def avgRange = 0.05 * Average(high - low, 20);
plot PatternPlot =
    IsUp[4] and
    IsUp[3] and
    IsUp[2] and
    IsUp[1] and
    IsUp[0] and
    close[1] < close[0] and
    close[3] < close[2] and
    close[2] < close[1] and
    close[4] < close[3];

PatternPlot.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
PatternPlot.SetDefaultColor(GetColor(0));
Thank BenTen. I was only planning to use it in TOS Scanner so is the SetPaintingStrategy and SetDefaultColor needed? The logic that you are using seems to ensure that closing price is higher than the opening price on each bar (IsUp) but even when I did my simple scan, I could see that close[4] was not lower than close[1]. I thought that was strange.

I assume IsDown, IsDoji and avgRange are not required?
 
Thanks BenTen.

The equivalent of what I originally wrote
plot scan = close > close[1] > close[2] > close[3] > close[4];
is
plot scan = close > close[1] and close[1] > close[2] and close[2] > close[3] and close[3] > close[4];

ThinkScript doesn't allow transitive chaining without the "and" keyword.

Still it's pretty cool, the power it gives you. Since Trade Ideas charges over $100/mth, I'm guessing they are more accurate and faster? It would be interesting to compare TOS scanners vs Trade Idea.
 
@PotOdds The question of:

Accuracy
TOS as a platform is highly accurate. Think of the lawsuits if the information wasn't. That said, I am not sure that using the 'close' variable will give you the most accurate picture of trend, if that is what you are striving for. Have you tried playing with: HLC3, HL2, or OHLC4, or even a short length simple moving average. They would all yield a more "accurate" view of trend.

Speed
I have no idea how often Trade Ideas alerts are updated. TOS Watchlists have a delay of 3-7min
 
@PotOdds The question of:

Accuracy
TOS as a platform is highly accurate. Think of the lawsuits if the information wasn't. That said, I am not sure that using the 'close' variable will give you the most accurate picture of trend, if that is what you are striving for. Have you tried playing with: HLC3, HL2, or OHLC4, or even a short length simple moving average. They would all yield a more "accurate" view of trend.

Speed
I have no idea how often Trade Ideas alerts are updated. TOS Watchlists have a delay of 3-7min

Thanks MerryDay. I was referring to how quickly and accurately (not missing) symbols that were trending very quickly on the 1 minute chart. Data accuracy I assume would be good. I'm just experimenting at the moment, learning ThinkScript language so I have some work to do. Yes, definitely close isn't going to give much, looking to incorporate volume, deviation, etc.

Yes I can see how slow the watchlists are. I saved my scan to the watchlist. I was refreshing on the main scan window and watchlist wasn't updating at the same time. This is probably what Trade Ideas and its $100/mth fee gets you. Very fast response and accurate symbol retrievals of fast moving stocks.

I've been trying similar tests in TradeStation's EasyLanguage but they have a limitation of 1000 symbols in their "scanner". Some debate as whether it is a scanner if you are restricted to such a small universe.
 
@PotOdds, thanks for sharing your scanner. How are you using it daily, only for intraday scalping strategies? or bullish? I am using this one to trade bullish tickers:
iqDCblM.png
 
Speed
I have no idea how often Trade Ideas alerts are updated. TOS Watchlists have a delay of 3-7min

I haven't seen any documentation regarding this being changed but I've noticed for the past week or so that a few of my Custom Watchlist Columns have been updating in real time... Custom Scan Results in Watchlists are still lagging the 3 - 7 minutes, however...
 
@PotOdds, thanks for sharing your scanner. How are you using it daily, only for intraday scalping strategies? or bullish? I am using this one to trade bullish tickers:
iqDCblM.png

Hi quijanoj44,
Sorry for late reply. I'm not on this forum much.

I'm trying to replicate Trade-Ideas intraday scanning. I figure if I can save on the $1000/year cost for TI, it would be a bonus. One major issue is that even though you can add your custom scans to a watchlist, the watchlist only updates like 3-5 minutes. There doesn't seem to be a way to increase the frequency. Having to push the scan button every minute is cumbersome. Plus I'm not sure how quickly TD backend servers work. This is one case where a paid service really matters. It would be great if TD beefed up their real-time scanning and charged a fee. I really like ThinkScript. I've since moved on to Cobra Trading as a daytrading platform. Have IBKR Pro which is pretty good but professional daytraders all seem to prefer Lightspeed, Cobra, CenterPoint as daytrading platforms.
 
Btw, not to say that I'm no longer on TOS. I'm now using ThinkScript to explore both day and swing trading strategies. One thing I'm currently working on is scanning for stocks nearing 52 highs with volume.
 
I was very impressed with Trade Ideas until I tried the demo for however long it gives you. Their built-in scans and real-time results are great. It wasn't flexible enough to create what I needed for the strategies I was using at the time. I was able to create the scans I needed in TOS.

Some YouTubers stream their Trade Ideas windows every day if you want to try that to get rid of the cost.
 
I was very impressed with Trade Ideas until I tried the demo for however long it gives you. Their built-in scans and real-time results are great. It wasn't flexible enough to create what I needed for the strategies I was using at the time. I was able to create the scans I needed in TOS.

Some YouTubers stream their Trade Ideas windows every day if you want to try that to get rid of the cost.
Thanks I've seen those. I don't want to rely on something that might go away in an instance. Plus they may not be looking for what I'm looking for. Yes, TI is a bit antiquated as they haven't updated in years but during the 2 week trial, they mentioned that they were completely revamping things. Merging something like ThinkScript into TI would be amazing. The way they have it now is a bit cumbersome. A million parameters to supposedly make it easier for the non-programming types.
 
Hi quijanoj44,
Sorry for late reply. I'm not on this forum much.

I'm trying to replicate Trade-Ideas intraday scanning. I figure if I can save on the $1000/year cost for TI, it would be a bonus. One major issue is that even though you can add your custom scans to a watchlist, the watchlist only updates like 3-5 minutes. There doesn't seem to be a way to increase the frequency. Having to push the scan button every minute is cumbersome. Plus I'm not sure how quickly TD backend servers work. This is one case where a paid service really matters. It would be great if TD beefed up their real-time scanning and charged a fee. I really like ThinkScript. I've since moved on to Cobra Trading as a daytrading platform. Have IBKR Pro which is pretty good but professional daytraders all seem to prefer Lightspeed, Cobra, CenterPoint as daytrading platforms.
Thanks for sharing your experience. I will look at the brokers you mentioned; I am not convinced with TOS.
 

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