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 INVESTOR
Very cool internship project guys, thanks for sharing :)
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.
Jovad Uribe
This is amazing!
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.
Jon Quant
Nice! Good luck with guys.
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 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.
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
Hi Hugh,
Thank you for the suggestion, we'll keep it in mind.
Best,
Shile Wen
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.
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.
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 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
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.
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.
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
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
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
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
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.
Josh M
Interesting; cool discussion and glad to see it's working live!
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
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?
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
Thanks for the update!
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
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.
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
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.
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
Thanks for the update!
I'm happy that Jovad included an options straddle, as I was planning to replace VXX in the Dragon portfolio with a rolling straddle on SPY to serve as the long vol component. As I haven't used options in QC before, Jovad's algo is very useful as a starting point.
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.
Sairaj Patil
This is amazing 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.
Jovad Uribe
Hi everyone,
This week Derek built a strategy he heard on episode #10 of the Better System Trader podcast. The guest, Perry Kaufman, explained the strategy idea came from George Douglas Taylor in the '50s, but Derek reversed the strategy rules. The strategy trades IWM and QQQ, and the backtest can be viewed here. It generates a 0.845 Sharpe ratio and a drawdown of 2.7% when backtested over the last several years.
Adding this strategy to the InternFund algorithm increases the diversification as we do not currently trade IWM or QQQ. Although the historical Sharpe ratio decreases slightly from 1.931 to 1.902, the compounding annual return increases from 6.845% to 7.019%, and the max drawdown decreases from 3.8% to 3.3%. With this new deployment, our backtest has a max drawdown of just $1,379. This deployment (with an increased max drawdown limit) is attached below.
Shile also built a Risk Parity strategy inspired by this article. During his research, he noticed that the drawdown was a whopping 43.4%, outlined in this backtest. To reduce this drawdown, the effects of risk parity were increased by shorting TBT, a -2x 20+ Years ETF, which gives us a positively leveraged position. Then, the dip of SPXL was bought, then sold using the Risk Management inspired by this Strategy Library Addition. See the results of the strategy here.
Previously, Ernest mentioned that our 60:40 strategy would exceed a 100% allocation ratio. We added an update to this strategy ensuring that it does not exceed this ratio. The line we updated is:
quantity = self.CalculateOrderQuantity(ticker, weight * self.SF_AR / sum(self.weight_by_ticker.values()))
Tamim Fund pointed out that our Fibonacci Option Straddle was primarily purchasing Apple. We converted the strategy to the algorithm framework and added a dynamic universe selection model to remove look-ahead bias. To further clarify the strategy's logic, if the market sentiment of a stock is down, the bid price for the call option will decrease and fall below the retracement level, causing a sell. If market sentiment is up, then the bid price may cross above the retracement, causing a buy. Many TA traders use this strategy, but their execution may take some time. The strategy attempts to enter the same position but quicker. I have attached the backtest here. As we cannot implement this in the InternFund, we will not continue with it.
As for the InternFund's performance, here is a screenshot of our latest track record.
This week our strategy lost 0.099276% of its value while SPY gained ~1.8%. Although this is a small setback, we aim to improve our algorithms alpha of 0.067.
Our backtest produces a whopping Treynor ratio of 2.298. It is no surprise that this ratio is high because the current risk-free rate (10YR Treasury Rate) is at a low 0.69%, and our beta of 0.031 is also low. However, this is one indication that our algorithm is a worthwhile investment.
Thanks for tuning in for this week's update. Constructive criticism and feedback help us build better strategies for the fund. Stay tuned for more updates!
Cheers,
Jovad Uribe
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
Hi Everyone!
We are planning on continuing the InternFund past summer!
This week, we are allocating 5% of our portfolio to Taylor Robertson’s post on using Leveraged ETFs. This led to a .4% decrease in drawdown as well as a 1.7% increase in the CAGR. Furthermore, our strategy is now very close to a Sharpe of 2.0, sitting at 1.98. After that, we increased the ratios of our existing strategies to take advantage of the cheap leverage offered by IB, and the new deployment algorithm is attached below.In addition, I also implemented a very simple seasonal strategy described in this article, and the results can be seen here. The high drawdown of 11.4% did not justify the returns of only 4.356%, so this strategy will not be making it into our InternFund algorithm.
Derek implemented an ETF rotation strategy that was sourced from RotationInvest. During each monthly rebalance, it calculates the trailing 3-month Sharpe ratio of SPY, EFA, and GLD. For the top-ranking ETF, it'll invest in it only if it's trading above its 150-day simple moving average. Otherwise, it allocates 100% of the portfolio to a bond ETF (TLT).
When backtested since 2015, this strategy generates a 1.218 Sharpe ratio and an annual standard deviation of 0.118. By comparison, the S&P 500 produces a 0.712 Sharpe ratio and 0.185 annual standard deviation over the same period. See the backtest results here. We will add this strategy to the deployment algorithm next week.
Furthermore, Jovad implemented the Golden Butterfly Portfolio from this article in this backtest. After a few alterations, he achieved a relatively low drawdown at 4.4% and a CAGR of 3.9%, and the updated backtest can be found here. Unfortunately, when added to our algorithm, the drawdown increases while the CAGR decreases (backtest), so it will not be making it into our live deployment.Our updated track record can be seen here:

And we are only $1 away from a new equity high!
Best Regards,
Shile Wen
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
Thanks for the update, Shile. What the InternFund is doing is very cool and I'm learning a lot.
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 7: A Little Turbulence
Hi everyone,
The InternFund had a sharp increase in volatility this week. However, we are still within our allowed max drawdown of $1000. Here's an image of our live track record over the last 7 weeks.
This week, we built a few more strategies with the hope of adding more to the InternFund algorithm.
Shile worked on a trend following strategy that measured the strength of the trend using an Ordinary Least Squares (OLS) model. When the past 50 days of close data have an r2 > .7, and the (current price - the average of the absolute values of the residuals) is at least the predicted value from the OLS model, we hold SPY, else, we liquidate our position. This model only had a Sharpe of .475 with a large drawdown of 34.2%, so this strategy will not be making it into the InternFund. The backtest can be found here.
I built a strategy that was inspired by Scott Andrews (aka "The Gap Guy"). Each market open, it fits a linear regression model using overnight gaps as the independent variable and the open-to-close returns as the dependent variable. It trains the model using the previous 10 weeks of data, using only weekdays that match the current trading day. After the model is trained, it predicts the direction of the current day's intraday return given the overnight gap and places its trade. The strategy achieves a 0.488 Sharpe ratio when backtested since 2015. See the backtest for reference. Since this strategy underperforms our benchmark, we didn't integrate it into the InternFund algorithm.
I also built a strategy I sourced from InvestiQuant that takes advantage of the long-bias in traders after a bull market breakout. Whenever the SPY has a multi-month breakout during a bull market rally but then gaps down into the next open, the strategy longs from the open until 15 minutes before the close. Backtesting the strategy since 2015 generates a 0.991 Sharpe ratio, outperforming the buy-and-hold Sharpe ratio of 0.742. See the backtest results here. After integrating this strategy into the InternFund algorithm, the Sharpe ratio of the algorithm backtest increases from 2.103 to 2.161. See the attached backtest for a copy of our latest deployment (with an extended drawdown limit).
In regards to the ETF rotation strategy we published last week, there was actually a bug in it. Line 71 should have read
if data[top_symbol].Price >= sma:
instead of
if data[symbol].Price >= sma:
After fixing this, the strategy underperforms the SPY, so we did not add it to our live deployment.
Thanks for tuning in for our weekly update!
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.
Mark Reeve
Hi guys,
I am wondering is it possible to combine several strategies like this using the algorithm framework?
Is there a reason you chose to avoid using the Algorithm Framework, other than simplicity?
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
Hi Mark,
It would be possible to combine these strategies using the Algorithmic Framework, however, we chose to stick with the classic algorithm because it is easier to account for multiple strategies.
From my experience, an algorithm developed using the Algorithmic Framework is best suited to a single signal type, however, our algorithm is a Frankenstein’s monster of various strategies that aren’t related. If we were to divide up our algorithm strategies into separate projects, then it would totally be viable for us to use the Algorithmic Framework on the strategies individually.
Best,
Shile Wen
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.
Samuel Schoening
You guys have helped me a lot so I just wanted to reach out and make sure you know that the orders for VXX may not be executing as you go back in history. This is because the price was over 30,000 in 2010 due to countless splits. Same goes for UVXY. The data is not adjusted so the order will not fill. That is why I just trade with 1 or 100 billion dollars in my backtests lol. With that said, this is very compelling research and do please keep up the good work!
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.
Josh M
It has been a few months -- any live trading update from the intern team?
Cool project and great work!
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.
Zicai Feng
hey interns, your self.max_dd is a fixed amount, should change it to a ratio as a % of the portfolio value. Because as your portfolio gets bigger due to profitable trades, a fixed amount that was set during a smaller AUM will just terminate your strategy randomly. I am sure Jared would understand and let you risk a fixed % of AUM rather than a fixed dollar amount with a fluctuating n growing AUM
Keep up the good work and build those RenTech libraries!
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
Hi Zicai,
Thank you. We will adjust the drawdown limit if the InternFund is launched again this summer.
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.
Zicai Feng
Hope it gets launched again :). Btw, similarly, your stop loss limit in your tesla example is a fixed amount. Similar reason to above, it should be a % number not a fixed $ amount as tesla price is all over the place depending on the price of dogecoins
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!