Hello everyone,
For the last month, Shile Wen and I, two Quantitative Developer Interns at QuantConnect, have been building trading strategies for a small in-house fund. We've spent the last several Friday afternoons working on this project and today we are excited to announce that we've deployed the fund's first two live trading strategies! In this post, we'd like to introduce ourselves, explain how users can emulate our workflow, and reveal the strategies we've deployed.
Introductions
Derek Melchin
I was first introduced to quantitative trading in the summer of 2018. Over the last two years, I've enjoyed spending my free time studying various quant finance topics and building personal projects. For the 2019-2020 school year, I accepted an executive position at the University of Lethbridge Finance Club. During my time there, I hosted several educational sessions and competed in the 2020 Rotman International Trading Competition as the algorithmic-focused team member. In the latter part of the academic year, I accepted an internship as a Quantitative Developer at QuantConnect. Now I utilize my background in software development and entrepreneurship to help the community and develop trading strategies.
Shile Wen
I was introduced to Quantitative Finance when I was browsing Quora, and came upon a post about the Medallion Fund, the legendary fund ran by Jim Simons and RenTec. I thought it was fascinating, and that’s what got me hooked. I currently attend the University of Washington, with a major in Computer Science. At UW, I partake in the Algorithmic Trading Club at my school. I hope to help the community with their issues and develop trading strategies (we have a Strategy Library for those that want to view strategies developed by interns) for the community.
Team Workflow
Shile and I both work in different countries, yet we've been able to remotely manage the InternFund together via the project collaboration feature. In short, we performed our research independently but merged our strategies together into one project after we validated their individual performance. The Algorithm Lab made deploying these strategies very simple. For an overview of the point-and-click process, check out this quick video.
InternFund Strategies
A concern some users have, and rightfully so, is that our staff may take their private strategies. Rest assured, we don't. Our terms of service and privacy policy explain this at great lengths. Shile and I don't even have access to users' private projects or the Alpha Streams algorithms. The strategies we researched and deployed for the InternFund can be found in public research papers.
The strategies we deployed are:
Algorithm
We merged the two strategies into one classic-style algorithm. A backtest of our live deployment is attached.
Future Updates
We hope to keep the community updated with the performance of the InternFund throughout the rest of the summer, so stay tuned!
Best,
Derek Melchin
Derek Melchin
Day 1: On the Up
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Pi..R
Very cool internship project guys, thanks for sharing :)
Jovad Uribe
This is amazing!
Jon Quant
Nice! Good luck with guys.
Derek Melchin
Week One: A Good Start
Hi everyone,
The live deployment has been profitable throughout its first week!
We researched some new strategies today but not find anything worth adding this week. Instead, we've decided to increase the allocation ratios of the two current strategies. This adjustment raises the Sharpe ratio of the backtest to 1.95 while maintaining a max drawdown <$1K. The <$1K drawdown is vital as the InternFund is only allowed a $1K drawdown.
Going forward, we are excited to research more strategies to add to our portfolio. We have a few in the pipeline, but are always looking for more. If our readers have anything they would like us to test, feel free to add suggestions to this forum thread.
See the attached backtest for the latest deployment.
Best,
Derek Melchin
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
HughStryker
Thank you for sharing, I look forward to following this thread.
I'd be very interested to see a QC implementation of Chris Cole's Dragon portfolio, i.e. 20% allocation to equities, bonds, trending commodities, gold and active long volatility. It was created in response to the typical 60/40 split so it would be nice to see how the two strategies compare.
Shile Wen
Hi Hugh,
Thank you for the suggestion, we'll keep it in mind.
Best,
Shile Wen
Ernest Shaggleford
Hi Derek and Shile,
thanks for revealing your strategies that you are trading live.
On the weights used for the 60:40 algo set of tickers:
self.weight_by_ticker = {'SPY': 0.6, 'AGG': 0.4, 'VXX': 0.1}
The total weight for this set is 1.1 which is then scaled by the allocation ratio of 0.5 so it would be 55%.
But as the TLT (treasury proxy) algo allocation ratio is 50% then the total portfolio allocation with both algos could potentially be 55% + 50% = 105% during the Treasury holding period, which doesn't seem correct.
Have I missed something?
Thanks,
ES.
Shile Wen
Week 2: The Hunt for the Next Strategy Addition
Hi Everyone,
This week, we’ve been researching new strategies for the InternFund. One strategy we researched is a Gap Down strategy, where we buy stocks during the day that surpass the previous day’s close if they open down 1% from the previous day’s close. However, the backtest (attached below) was not promising, so it will not make it into the InternFund. We also developed an option spread strategy, however, we deemed that the drawdown was too large, thus, this strategy will not be added either.
Here is the performance of our portfolio for this week.
Ernest Shaggleford pointed out that with our current ratios, we’d have 105% allocation during periods when we hold TLT. We confirmed that our account has access to overnight margin, which means going over 100% allocation will not affect our algorithm.
As for next week, we will implement HughStryker's suggestion and keep researching new strategies.
Best,
Shile Wen
Ernest Shaggleford
Hi Shile,
re: "We confirmed that our account has access to overnight margin, which means going over 100% allocation will not affect our algorithm":
Out of curiousity, won't the cost of margin have some impact on the P&L?
Thanks,
ES.
HughStryker
Thanks for the update, Shile!
Here is another strategy idea, I'm too much of a beginner to accurately describe it, but I'd say it's a L/S portfolio using institutional ownership as a factor. There's a variation which uses long/short interest instead.
BofA version
ZeroHedge variation
Derek Melchin
Hi everyone,
Just a quick update: InternFund closed at a new high today!
Stay tuned for a more comprehensive update this Friday.
Best,
Derek Melchin
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Shile Wen
Week 3: Researching More Strategies
Hi Everyone!
This week, we researched more strategies for the InternFund. One strategy we tested this week was HughStryker’s suggestion, Chris Cole’s Dragon Portfolio. Although the drawdown is relatively low compared with other strategies, it is still too high for us, so we decided not to add it. An implementation can be seen in the attached backtest.
Derek implemented a Trailing Breakout Strategy with TSLA. It performs well throughout 2020. However, extending the backtest start date further into the past decreases the performance. For the InternFund we are specifically looking for strategies with a long track record of consistent returns.
As for the InternFund performance, we are at a new equity high! Five days ago, we entered our first TLT trade, and we have exited TLT today, for a gross profit of $76.54. Here is the graph of our equity:
Ernest Shaggleford mentioned that margin will affect our P/L, which is true, however, we have very low margin interest, and we only hold TLT for five days out of the month, so the costs are negligible. HughStryker offered another strategy of incorporating institutional ownership. Unfortunately, we do not have access to this data.
Thanks to everyone for tuning in to our weekly update, and special thanks to HughStryker for the Dragon Portfolio strategy suggestion! Stay tuned for more updates, and feel free to suggest more strategies.
Best,
Shile Wen
Josh M
Interesting; cool discussion and glad to see it's working live!
Tamim Fund
Shile,
The Gap Down strategy seems to be executing at "stale prices," resulting in there being no price gain or loss other than the commission, since you are comparing the current days close to the previous days close and placing a buy order after market closes, instead of comparing intraday minute or hourly price data. Could you look at that?
HughStryker
Thanks for the update!
Derek Melchin
Hi Ernest and Tamim Fund,
We appreciate the constructive feedback. However, the InternFund is limited to only trading equities. Thus, we cannot implement the suggestions #2 & #3 from Ernest above. As for the Dragon portfolio changes, we will take a closer look at this today.
In regards to the stale prices in the Gap Down Strategy, we will work to resolve this today as well.
Best,
Derek Melchin
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Derek Melchin
Week 4: Up To Three Strategies!
Hi everyone,
We are excited to announce that the InternFund generated profits for another week. Here's the latest screenshot of our live track record.
Today, we spent some time fixing the "stale price" issue with the Gap Down strategy. The issue surfaced because the universe resolution was set to daily in the original algorithm while the strategy was trading off intraday prices. Here is the backtest of the strategy after fixing the bug. Thank you Tamim Fund for reporting this issue.
This week, we also spent some time implementing the Turnaround Tuesday strategy. As can be seen from this backtest, the strategy has performed quite well over the last few years. Allocation 33% of the portfolio to the strategy generates a 58% win rate, >1 Sharpe, and a mere 1.6% drawdown. We are confident enough in these results that we've decided to deploy this strategy to live-trading within the InternFund algorithm. To incorporate the strategy, we reduced the allocation ratio of the 60/40 strategy to 30%, allowing the Turnaround Tuesday strategy to have a 20% portfolio allocation.
We found out today that the post of our latest live deployment above actually quits early because it reaches our max drawdown limit of $1000. After increasing the max drawdown limit so the backtest completes, the original max drawdown was 6.3%. With the Turnaround Tuesday strategy incorporated into the algorithm, the new combined strategy experiences a 3.8% drawdown. The Sharpe ratio is also increased from 1.64 to 1.93. We will of course only deploy the new strategy with the $1000 max drawdown limit, but a complete backtest of the InternFund algorithm (with an extended drawdown limit) is attached below.
For those readers who may have missed the discussion thread introducing our newest team member, we'd like to introduce Jovad to this thread. He implemented an interesting strategy this week while researching for the InternFund. It's a Fibonacci Option Straddle strategy that sets a retracement at 30% below the 5 day maximum of the underlying security. Every two hours a scheduled event is triggered checking if the nearest expiring and strike price option's bid price has met or crossed the set retracement. If this is true, then we enter a long position. If it's false, we liquidate our position, or we do nothing. Lastly, the universe was selected based on equities that have had a historical Implied Volatility <=35% for the options with the nearest strike price. The strategy performed well but it would cost the fund $400/month for an options data feed in our account and would cancel out returns.
Thank you everyone for following along with our live track record. The support and constructive criticism gets us excited to work on this each Friday. As always, we encourage our readers to stay involved by requesting trading strategies for us to test for the InternFund.
Stay tuned,
Derek Melchin
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Tamim Fund
For the option straddle strategy, it only gets the option with the absolute lowest strike price. The expiry doesn't matter since it is sorted by the strike price afterwards.
Could you explain the logic behind this strategy? It seems that it relies on the variety of the underlying options, since only very very deep ITM calls will be worth between .7 and 1.3x the security price, instead of relying on some trading principle.
Tamim Fund
I just ran it, and the reason it works is because 99% of the time, the only call options with a low enough strike price to fit the parameters is apple's and sometimes, GS, V, TGT, and MSFT. Apple has been going up for the past decade. About 80% of the orders over the past 5 years is just Apple. In the past year, there has been more Microsoft, but it is still mostly Apple.
If I am wrong, please correct me.
Derek Melchin
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 QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect 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. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!