YungTraderFromMontana
Well-known member
I'm looking for something that can detect consolidation so I can stick to trading trends.
Thanks.
Thanks.
Join useThinkScript to post your question to a community of 21,000+ developers and traders.
I'm looking for something that can detect consolidation so I can stick to trading trends.
input spanOfBase = 8;
input maxPrctCorrection = 10;
input spanOfBreakoutHigh = 42;
def flatBaseHigh = highest(high[1], spanOfBase);
def flatBaseLow = lowest(low[1], spanOfBase);
def percentMaxCorrection = AbsValue(100 * (flatBaseLow / flatBaseHigh - 1));
def withinPrctCorrectionLimits = percentMaxCorrection <= maxPrctCorrection; def highShade = if withinPrctCorrectionLimits then flatBaseHigh else flatBaseLow; def lowShade = if withinPrctCorrectionLimits then flatBaseLow else flatBaseHigh; def flatBase = highShade > lowShade;
def highestHighForBreakout = highest(high[1], spanOfBreakoutHigh);
def currentBreakoutHigh = high > highestHighForBreakout;
# only one of these can be scanned for at one time. Use "#" comment marks to turn off
# the one you don't need
#plot flatBaseFormation = flatBase and currentBreakOutHigh == 0;
plot breakOutSignal = currentBreakOutHigh and currentBreakOutHigh[1] == 0 and flatBase;
@Johnny Cash Absolutely no problem, Just load that code into the scanner and select Weekly aggregation. I just scanned this against the S&P 500 using a weekly aggregation and obtained 10 results.
What is MTF HA and Hull turning? What is the timeframe you use - 1minute?I use MTF HA pair it with Hull turning and Fib support resistance levels .works really good in ES and ZB,which I trade.
heres an idea. Its not what you are refering to, but why dont you try to look for stocks where the daily rsi is between 60 and 40. because usually when rsi is above 70 or below 30 is trending. or reversing back to the mean, but it is moving, consolidation is difficult to gauge in my opion, just like trend is difficult, because things are consolidating or trending until they are not. you could also look for wedge patterns. technically thats a geometrical consolidation.Does anyone know of a script or how to make a script to scan stocks in consolidation patters? I tried thinkorswim's pattern search option and it isn't that great. The things I've noticed about consolidation patterns is that it follows after an impulsive move up. I guess the correct search parameters would be to scan for a stock that has high volume with large price movement in the last 10-25 days followed by a decrease in volume. I wanted to add that I tried using the thinkorswim quick script wizard and I did more harm than good. lol. Can anyone offer any insight or point me to the right location? Thank you all.
That's some good advice. I had no luck with the RSI in the past but I think I have to learn to stick with one method and use it for while before I determine if the method is right for me. The wedge pattern is also good thinking. I'm gonna give those a try as well.heres an idea. Its not what you are refering to, but why dont you try to look for stocks where the daily rsi is between 60 and 40. because usually when rsi is above 70 or below 30 is trending. or reversing back to the mean, but it is moving, consolidation is difficult to gauge in my opion, just like trend is difficult, because things are consolidating or trending until they are not. you could also look for wedge patterns. technically thats a geometrical consolidation.
i mean the rsi on a daily chart, each candle as a day. but honestly when people say follow "trend" its bullshit because something thats trending on a 5 minute chart might not be on a 4 hour chart. thats why is good to look at different time frames. and in my opinion thats why consolidation happens, price gets caught up between two time frames. so one time frame want to go up and then the other down. usually the higher time frame wins(usually i think). hopefully thats not confusing.That's some good advice. I had no luck with the RSI in the past but I think I have to learn to stick with one method and use it for while before I determine if the method is right for me. The wedge pattern is also good thinking. I'm gonna give those a try as well.
Just a few observations I had when thinking about your question. Consolidation will often times occur after large spikes in volatility (which can be measured with Bollinger Bandwidth or Keltner Bandwidth). After a spike, you can look for Balance of Volume to fade along with a fade in volatility and a narrowing price range (typically leading to a squeeze before the next big move). Just some thoughts. You can see some of what I am referring to in the image below. I would scan for bandwidth pulling off the 75 period length bulge and BoV pulling away from its 40 period length bulge. Again, I haven't tried this out yet, its just a thought. I hope it helps!Does anyone know of a script or how to make a script to scan stocks in consolidation patters? I tried thinkorswim's pattern search option and it isn't that great. The things I've noticed about consolidation patterns is that it follows after an impulsive move up. I guess the correct search parameters would be to scan for a stock that has high volume with large price movement in the last 10-25 days followed by a decrease in volume. I wanted to add that I tried using the thinkorswim quick script wizard and I did more harm than good. lol. Can anyone offer any insight or point me to the right location? Thank you all.
Thread starter | Similar threads | Forum | Replies | Date |
---|---|---|---|---|
M | Best Daytrading Strategies For SPY | Questions | 6 | |
S | What is the best way to identify the choppy price action? | Questions | 1 | |
Best editing tool in ThinkOrSwim | Questions | 1 | ||
F | Best Support/Resistance Indicator for ThinkOrSwim | Questions | 1 | |
Curious | Best BACKTESTED Results You Have Achieved | Questions | 2 |
Start a new thread and receive assistance from our community.
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.
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.