Strategy Library

Small Capitalization Stocks Premium Anomaly

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.HasFundamentalData 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 FineSelectionFunction(self, fine):
    if self.year == self.Time.year:
        return self.symbols

    # Calculate the market cap and add the "MarketCap" property to fine universe object
    for i in fine:
        i.MarketCap = (i.EarningReports.BasicAverageShares.ThreeMonths * 
                       i.EarningReports.BasicEPS.TwelveMonths *
                       i.ValuationRatios.PERatio)

    sorted_market_cap = sorted([x for x in fine if x.MarketCap > 0], key=lambda x: x.MarketCap)

    self.symbols = [i.Symbol for i in sorted_market_cap[:10]]
    return self.symbols

In OnData(), we buy 10 stocks in the list of lowest market-cap. The portfolio is rebalanced every year.

Algorithm

div class="qc-embed-frame" style="display: inline-block; position: relative; width: 100%; min-height: 100px; min-width: 300px;">