Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Algorithm Price Drop Help

I need some help making a part of an algorithm where if the share price drops by 5% sell all of the shares and then only start buying the share again if the price increases by 2%.

Any suggestions?

1 response

@Callum M. You can start with the % change algo and modify it to suit your needs.
Note: numpy and talib are not necessary for this algo. I just tend to leave them in as most strats eventually need them.
[Updated]