Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Finding point of current Trend

Hello to all!
I'm newbie on Quantopian, but find very good and interesting topics right here!
Shortly about myself: I'm 23 yo man from Ukraine, trading US futures market for 3 years by hands and working on automatization my system.
I have some interesting trouble with finding trend points. So why I created this topic.

So, what do I mean:
I have nice enter points, using z-score formula on instrument. It works nice and shows not bad results for finding enter (also exit points). But the problem I want to solve is give enters only by the trend.
The main thing is that I want to teach my system to recognize in what point of current trend we are.

I'm entering Long Position when the z-score goes to -2 and then backs >-2.
Short position when z-score goes higher 2 and backs <2.

I tried to use the next things:
- found trend with some Momemntums on different Timeframes and looking "Trend Power" depends on which value I got (like in this video: https://www.man.com/2/ahl-explains-momentum ) but using Custom timeframe.
- found trend with MA (the worst variant)
- looking trend with ZigZag indicator and finding zones where I need to Buy or Sell
(here is the screenshot of that zone (red - sell, green - buy): https://gyazo.com/064fc404a6a990657167a8fe8194bc47

But in all these variants I always getting some mistake which may resolve the problem and give very resultative trading strategy.
As you can see on the chart from this screenshot this z-score gives very nice intraday entries (and not only intraday):
https://gyazo.com/03d05f6602363538e89fc736f9467540
On this screenshot I pointed the enters I want to strategy works.
And on next I want to filter that enters, but don't have any more ideas how to do it:
https://gyazo.com/bfa1a6cfb1dda0e71b37ff5d8f804822

Daily charts:
Nice Enter Points:
https://gyazo.com/2dd679e257e5d4011b90e355e13115dd

Don't want to allow trades here:
https://gyazo.com/8234ff4dd6914b260e660ca47d15a356

The Main problem as I think:
Find the Trend Point in which we are right now and depends on it - allow or not enters into position.

I want to ask your help, guys! Maybe we can create something very usefull.

p.s.: Also forgot one more method I tried to use:
- using z-score signal from higher Timeframe (60 min or higher) for setting-up the trend - if we have the long signal - so we looking longs only on main Timeframe (f.e. 5 or 15 mins). The same with short trades.