Introduction
Small caps are typically defined as companies with market caps that are less than $2 billion. The advantage of investing in small cap companies is that they are young companies with significant growth potential. However, the risk of failure is greater with small-cap stocks than with large-cap and mid-cap stocks. In this algorithm, we will explore the performance of the small-capitalization investment.
Method
The first step is coarse universe selection. We create an investment universe with stocks that have fundmental data and with a price greater than $5.
return [x.symbol for x in coarse if x.has_fundamental_data and x.price > 5]
In fine universe selection, we sort the stocks in the universe by the market capitalization and choose 10 stocks with the lowest market cap.
def fine_selection_function(self, fine):
''' Selects the stocks by lowest market cap '''
sorted_market_cap = sorted([x for x in fine if x.market_cap > 0],
key=lambda x: x.market_cap)
return [x.symbol for x in sorted_market_cap[:self.count]]
In OnData(), we buy 10 stocks in the list of lowest market-cap. The portfolio is rebalanced every year.
Derek Melchin
See the attached backtest for an updated version of the algorithm with the following changes:
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.
Jing Wu
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!