I'm trying to understand how to short and take profit with a momentum swing in the market using QC. This simplistic example implements the core of what I'm discussing. I want to short the market and then capture a certain number of basis points when the market drops in price. The statistics confuse me. How can I win 100% of the time and my average win be 0%? Am I shorting and capturing my short correctly here? Limit orders should gaurantee a price. My average win should be 10 basis points set in this algorithm. 

1) Am I shorting and setting a limit around my short correctly?

2) How am I losing money when I win 100% of the time?

3) Why isn't my average win 10 basis points?

Author