Skip to content

Open Source Asset Pricing

Menu
  • Data
  • Code
  • FAQ
  • Signal Browser
Menu

Code

All code for the project is available on Github: https://github.com/OpenSourceAP/CrossSection/

  • Check out the code to understand how each signal is constructed
  • If you find mistakes, please let us know by opening an issue
  • If you want to provide code to construct additional signals, open a pull request to let us integrate it in the code base

In addition, we provide demo code to illustrate a few simple things one can do with the datasets that we provide: https://github.com/OpenSourceAP/CrossSectionDemos

  • Each file is an independent script that automatically downloads data from the internet. You just need the googledrive R package and a Google Drive account.
  • For instance, the plot_anomaly.R lets you plot an anomaly’s cumulative return together with sample end and publication dates:

Code releases

  • Currrent release (v2.0.0): Major Python signals translation update, annual improvements
  • Previous release (v1.4.1): AnnouncementReturn lookahead bias patch
  • Previous release (v1.4.0): Annual improvements
  • Previous release (v1.3.0): New predictors, annual improvements
  • Previous release (v1.2.0): New predictors, Fama-French style 2×3 portfolios
  • Previous release (v1.1.0): Daily returns, more monthly implementations, completeness checks
  • Previous release (v1.0.0): Major modularization update
  • Older beta releases

To Download Data

  • Head to the Data tab
  • Use the openassetpricing Python package (by Peng Li)
  • Use the OpenSourceAP.DownloadR R package

Authors

Andrew Y. Chen
Tom Zimmermann

News

2025-10-22: Data update (October 2025)

  • Major code update: Signals translated to Python
  • Various other minor fixes and improvements
  • Head to the data page and our repo for details

2024-10-14: Data update (October 2024)

  • Fixes lookahead bug in AnnouncementReturn
  • All other data same as August 2024 release

2024-08-22: Data update (August 2024)

  • Portfolios updated to end of 2023
  • Various minor fixes and improvements

2023-08-16: Data update (August 2023)

  • Portfolios updated to end of 2022
  • Five additional signals
  • Various minor fixes and improvements

2022-03-30: Data update (March 2022)

  • Portfolios updated to end of 2021
  • Two additional signals
  • 2×3 Fama-French factor style portfolios
The views expressed herein are those of the authors and do not necessarily reflect the position of the Board of Governors of the Federal Reserve or the Federal ReserveSystem.
This project has received support from the Deutsche Forschungsgemeinschaft (DFG) under Germany’s Excellence Strategy EXC2126/139083886.
© 2025 Open Source Asset Pricing | Powered by Minimalist Blog WordPress Theme