Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Using Historic Performance & Stock Fundamentals to Create a Portfolio of decent CSR Stocks

Based on the research I completed on businesses with good corporate social responsibility in another thread, I wanted to create a reasonable method of picking stocks based on an arbitrary ruleset on the fundamental signals from the stocks themselves. The previous backtesting showed that historically, the better performing CSR stocks had:

  • High P/E ratios (speculative investors looking for capital growth)
  • Low PEG (0.1 - 1.0 - Undervalued stocks)
  • High beta * P/E - Slightly more volatile stocks
  • Positive growth shown through long and medium term moving averages

I ranked all of the 250 stocks in the CSR spreadsheet using these various indicators and was able to select 30 stocks arbitrarily (i.e. just using math). I then created a simple rebalance algo of the top 30 stocks that met those criteria, putting 3.3% of money into each one and rebalancing every 24 days.

It should be noted that it is almost impossible to avoid all look-ahead / look-behind bias, especially around the MAV, but hopefully this will give other algo builders a reasonable foundation for CSR stocks. The businesses I included based on the rules were as follows:

Global Cash Access Holdings, Inc.
Taiwan Semiconductor Manufacturing Company Limited
Armstrong World Industries, Inc.
Autodesk, Inc.
WGL Holdings Inc.
Polypore International Inc.
Maxwell Technologies, Inc.
Baker Hughes Incorporated
Masco Corporation
LSI Industries Inc.
United Microelectronics Corporation
NRG Yield, Inc.
Orbitz Worldwide, Inc.
Schlumberger Limited
Pebblebrook Hotel Trust
SunPower Corporation
Trex Co. Inc.
Pegasystems Inc.
K12, Inc.
Swift Transportation Company
Adobe Systems Inc.
Cardtronics Inc.
SunOpta Inc.
Starbucks Corporation
Prologis, Inc.
Green Plains Inc.
Pacific Ethanol, Inc.
Cubist Pharmaceuticals Inc.
Headwaters Incorporated
Impax Laboratories Inc.