"What I cannot create, I do not understand" (Richard Feynman)
A python toolkit for empirical asset pricing models and risk premia estimation. The currently available models for estimation of risk premia are:
TimeseriesReg: single-pass OLS time-series regression, described in Cochrane (2005), Section 12.1
CrossSectionReg: two-pass cross-sectional regression, described in Cochrane (2005), Section 12.2
NonTradableFactors: iterative maximum-likelihood estimator for non-tradable factors, described in Campbell, Lo & MacKinlay (2012), Section 6.2.3
RiskPremiaTermStructure: term structure of risk premia with a single factor, tradable or not, following Bryzgalova, Huang & Julliard (2024). I would like to thank the authors for sharing their replication files.
This library is in active development and aims to implement models from all corners of the literature.
Python implementation of "Pricing the Term Structure with Linear Regressions" from Adrian, Crump and Moench (2013). This library prices the time series and cross-section of the term structure of interest rates using a three-step linear regression approach. Computations are fast, even with a large number of pricing factors. Generates estimates for term premium, risk neutral yields and expected returns.
I would like to thank Emanuel Moench for sharing his replication files of the original paper. I made sure to match each computation step with the authors’ original implementation.
Python package to run Bayesian Fama-MacBeth Regressions from Bryzgalova, Huang & Julliard (2024). As presented by the authors, this methodology provides reliable risk premia estimates for both tradable and non-tradable factors, detects those weakly identified, delivers valid credible intervals for all objects of interest, and is intuitive, fast and simple to implement.
This is a Python library to specify, calibrate, solve, simulate, estimate and analyze linearized DSGE models. The specification interface is inspired by dynare, which allows for symbolic declarations of parameters, variables and equations. Once a model is calibrated or estimated, it is solved using Sims (2002) methodology. Estimation uses Bayesian methods, specifically Markov Chain Monte Carlo (MCMC), to simulate the posterior distributions of the parameters. Analysis tools include simulation, impulse-response functions, historical decomposition and extraction of latent variables.
This is my first published python library. I started this project during the COVID pandemic with the objective of refreshing and consolidating my studies on DSGEs.