Back to Community
Developing a Trend System

Hello all,

First of all, I am a newcomer to Quantopian and to programming in general. I have always wanted to delve into this as I would like to gain insights on trading strategies and test new ideas and such. I am very limited to what I can actually do as of now.

I would like to ask if I can receive some help on developing a notebook in order to trade the following system

Long Condition
If price trades above the 20 day High enter a long position with Stop loss=(ATR(20)x2) risking 1% of our capital.

Simultaneously, an alternative exit would be if price trades below the 10 day Low and that price is above our ATR placed Stop loss then we exit that position.

Short Condition
Same concept, but vice versa.

I have only been learning to code for the past month, my skills and capabilities to express these rules in code are still a very hard concept for me to wrap my head around. I would be grateful if some help can be provided as it is much easier to understand once you are able to visualise what you are trying to do.

Kind regards,

Antonis Zakheos