Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Strange fill prices

Hi, did anyone encounter fill prices that just simply does not look possible before?

For example, my algorithm did a paper trade yesterday on IEF at 1500 US Eastern time and 769 shares (pretty insignificant for an ETF that sees an average daily volume of 2 mil) was filled at an average of 109.92 when the entire day's range was only 109.18-109.66 based on my broker (Interactive Broker). I counter check the day's range against yahoo finance and they were about there. So the fill price just does not look mathematically possible?

2 responses

I'm assuming you're using the default slippage model?

Check out the help doc where we walk through an example of the how the Volume Share slippage model works. Doing a quick eyeball of the stock, it looks like the minutely volume ranges from 100 to 3000 shares per minute. I'm guessing your algo's order was live during some of those low-volume minutes. In that case, your order is taking the maximum 25% of the bar that it can, and it's experiencing the maximum .625% price penalty too. 109.92/1.00625 = 109.24, so that all lines up.

You've got a couple options.

  1. Change your order management to place smaller orders. I've seen people do things like tracking a trailing window of volumes, and then aiming for 15% of a bar, things like that.
  2. Explicitly set your slippage model to be more forgiving.
Disclaimer

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by Quantopian. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. No information contained herein should be regarded as a suggestion to engage in or refrain from any investment-related course of action as none of Quantopian nor any of its affiliates is undertaking to provide investment advice, act as an adviser to any plan or entity subject to the Employee Retirement Income Security Act of 1974, as amended, individual retirement account or individual retirement annuity, or give advice in a fiduciary capacity with respect to the materials presented herein. If you are an individual retirement or other investor, contact your financial advisor or other fiduciary unrelated to Quantopian about whether any given investment idea, strategy, product or service described herein may be appropriate for your circumstances. All investments involve risk, including loss of principal. Quantopian makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances.

Thanks for the clarification, Dan