Quant Mashup Are hedge funds losing their hedge? [Mathematical Investor]“Hedge funds” were pioneered some 70 years ago by Australian financier Alfred Winslow Jones. His idea was to combine a “long” position (i.e., one that profits if the securities go up in price), typically a set of growth stocks, with a “short” position (i.e., one that profits if the(...) Thematic versus Momentum Investing [Finominal]Thematic products underperform the stock market on average The exposure to the momentum factor was low to negative recently Systematic performance chasing beats performance chasing with a narrative INTRODUCTION Space: the final frontier. Where no man has gone before…. Well, wealthy folks can now(...) The Effect of Indexing on Price Discovery and Limits to Arbitrage [Alpha Architect]The rise of stock indexing has raised concerns that index investing distorts stock prices—indexers are free riders who rely on prices without contributing to price discovery, thus reducing price efficiency. Byung Ahn and Panos Patatoukas, authors of the study “Identifying the Effect of Stock(...) QuantConnect Integration with MlFinLab [Hudson and Thames]Announcing that MlFinLab is fully integrated into the powerful backtesting and execution platform of QuantConnect! At the start of 2022, we set out to improve the user experience across all of our products and to improve the accessibility of our libraries. This meant integrations into platforms that(...) Correlation Matrices Denoising: Results from Random Matrix Theory [Portfolio Optimizer]The estimation of empirical correlation matrices in finance is known to be affected by noise, in the form of measurement error, due in part to the short length of the time series of asset returns typically used in their computation1. Worse, large empirical correlation matrices have been shown to be(...) The Best Defensive Asset Class [Allocate Smartly]In this post we look at what major asset classes have proven to be the best defensive choice in months when the market has fallen over the last 50+ years. We’ll look at multiple government and corporate bond assets, diversified commodities, gold and the US dollar. The results? As expected, a mixed(...) Stock-Bond Correlation, an In-Depth Look [Quantpedia]The recent surge in global inflation sent shock waves across financial markets and affected the complicated relationship between stocks and bonds. Today, we would like to present you with a review of two interesting papers, which provide both a deep and easy-to-understand examination of the(...) Causality: interest rates and fixed income assets [Quant Dare]The blog has previously addressed interest rates in a post that splits the yield rate curve into three relevant components. This time this post tries to identify the influence of interest rates on fixed income assets by using the Granger causality test. Interest rates obviously have a strong impact(...) Finding and analyzing free stock index data with Python and EDGAR [Wrighters.io]A stock index is just a list of stocks. But an index is a special list because investors use it to make investing decisions. An index is constructed via rules about stocks to include, how much to include, and when to include (or remove it). Finding this data, especially for more obscure indexes, can(...) Democracy: is it better for the stock market? [Alpha Architect]In this article, we examine the research that addresses the question of whether or not democracy leads to better possible outcomes for the stock market. Democracy and Stock Returns Xun Lei and Tomasz Piotr Wisniewski SSRN Working Paper A version of this paper can be found here Want to read our(...) Crypto-Trading with REST, part 1 [Financial Hacker]Many brokers and exchanges can nowadays be accessed online with a REST API. The days of awkward proprietary broker APIs are coming to an end. This article is a step by step instruction of implementating a REST API interface in plain C for connecting a trading system to the Bittrex cryptocurrency(...) Is the Carry Trade a Diversifying Strategy? [Finominal]The carry trade was positive across most asset classes in YTD 2022 The correlations to the S&P 500 were low historically However, the carry trade crashed when stocks crashed, ie provided limited diversification benefits INTRODUCTION After a few years in unchartered territories, most bonds have(...) Slava Ukraini! Latest from Quantocracy contributor in Ukraine: Natural Clustering in VIX Futures Data [Only VIX]If you take all available VIX futures data and create a scatterplot of daily settlement prices as a function of time to expiration you will see a curious pattern: Yes, there are clear clusters in prices. But what do these clusters mean? The simple explanation is that the VIX term structure passes(...) Volatility and Expected Range, Are They The Same? [Only VIX]This is not a post to correct some abstract mathematical technicality, or a semantic point. Rather I hope to shed some light on widespread mis-estimation of important risk metric that I often see on the internet. For example this double-decker of ignorance popped up on my twitter feed today. VIX as(...) Jobs growth as trading signal [SR SV]Employment growth is an important and underestimated macro factor of financial market trends. Since the expansion of jobs relative to the workforce is indicative of changes in slack or tightness in an economy it serves as a predictor of monetary policy and cost pressure. High employment growth is(...) Lottery Demand and the Asset Growth Anomaly [Alpha Architect]It is well documented in the literature that over the long term, low-investment firms have outperformed high-investment firms—with the negative relation between asset growth (AG) and future stock returns particularly featured by the overvaluation of high AG stocks. This finding has led to the(...) How to Improve Post-Earnings Announcement Drift with NLP Analysis [Quantpedia]Post–earnings-announcement drift (abbr. PEAD) is a well-researched phenomenon that describes the tendency for a stock’s cumulative abnormal returns to drift in the direction of an earnings surprise for some time (several weeks or even several months) following an earnings announcement. There(...) $NDX Performance After 5 Down Days and a 150-Day Low [Quantifiable Edges]The two big up days to start last week have now been followed by 5 down days in a row. And the 5-day selloff has put the NDX at a new bear-market closing low. The study below looks at other times since 1990 that NDX closed down for the 5th consecutive day and at a 150-day low. NDX performance after(...) Sell in May and go away… Just won’t go away [Quant Dare]In this post we are going to revisit (check previous post) the catchy market maxim ”sell in May and go away”. After 2 bear markets in the last 3 years and yet another red September, once again, here I am in October, wishing I had sold in May. Let’s simulate the different variations of this(...) Building a Raspberry Pi Cluster for QSTrader Using SLURM - Part 4 [Quant Start]In the previous article in this series we installed and configured SLURM to enable us to parellelise work loads. In this article we will be using SLURM to install QSTrader on all our secondary nodes. This will enable us to multiple run parameter sweeps for backtests of single or multiple strategies(...) Random Forests and Boosting for ARCH-like volatility forecasts [Sarem Seitz]In the last article, we discussed how Decision Trees and Random Forests can be used for forecasting. While mean and point forecasts are the most obvious applications, they might not always be the most useful ones. Consider the classic example of financial returns, where the conditional mean is hard,(...) Conditional Portfolio Optimization [EP Chan]Previously on this blog, we wrote about a machine-learning-based parameter optimization technique we invented, called Conditional Parameter Optimization (CPO). It appeared to work well on optimizing the operating parameters of trading strategies, but increasingly, we found that its greatest power(...) Momentum Everywhere, Including Emerging Markets [Alpha Architect]In order for investors to determine which of the hundreds of factors in what John Cochrane famously called the “zoo of factors” were worthy of investment, Andrew Berkin and I set out seven criteria in our book “Your Complete Guide to Factor-based Investing.” For a factor to be considered, it(...) Research Review | 7 Oct 2022 | Interest Rates and Inflation [Capital Spectator]The Factor Multiverse: The Role of Interest Rates in Factor Discovery Jules H. van Binsbergen (University of Pennsylvania), et al. September 2022 We study the importance of the decline in interest rates in the discovery of asset pricing anomalies. We investigate 153 discovered anomalies as well as(...) Multi Strategy Management for Your Portfolio [Quantpedia]If you follow Quantpedia’s blogs, you probably know that Quantpedia PRO already contains multiple risk management and portfolio construction tools for your quantitative investment strategies. For example, Crisis Hedge can find you suitable investment hedges for negative months and for bear(...) Factor Olympics Q3 2022 [Finomial]Value is leading the performance scoreboard in YTD 2022 Low volatility is the worst-performing factor Oddly, the value and low volatility factors are strongly positively correlated INTRODUCTION We present the performance of five well-known factors on an annual basis for the last 10 years.(...) Transaction costs and portfolio strategies [SR SV]Transaction costs are a key consideration for the development of trading strategies; and not just in final profitability checks. Indeed, disregard for trading costs at the design stage leads to excessive reliance on fleeting small-scale characteristics for return predictors. It also skews the(...) The Probabilistic Sharpe Ratio: Hypothesis Testing and Min Track Record Length [Portfolio Optimizer]In the first post of this series about the Sharpe ratio considered as a statistical estimator, I introduced a probabilistic framework to answer the question What is the probability that an estimated Sharpe ratio is statistically significantly greater than a reference Sharpe ratio? In this second(...) How Much Can You Lose with Bonds? [Factor Research]Bonds are typically considered safe investments However, there were decades of negative real returns Drawdowns reached 50% for U.S. Treasuries and Bonds INTRODUCTION Inflation greater than 10% was unknown for the majority of people in developed markets before this year, but it is nothing(...) Use pandas DateOffsets for easy date manipulation [Wrighters.io]So much useful data has a date or time component. Often, data has a timestamp to represent when the data was acquired, or when an event will take place, or as an identifying attribute like an expiration date. For this reason, understanding how to work with dates and times effectively can be a very(...) Inflation-Linked Bonds for Inflationary Periods? [Factor Research]Inflation-linked bonds are considered inflation-hedges However, these have lost almost as much as plain-vanilla bonds in 2022 The sensitivity to interest rates matters more than that to inflation INTRODUCTION Inflation is the biggest issue facing the U.S. and is more important to citizens than(...) Sector vs Factor-based Benchmark Selection [Factor Research]Manager-selected benchmarks are suboptimal as they are not free of conflict of interests Investors can use sectors to identify more appropriate benchmarks However, this ignores factors, which are better at explaining investment returns INTRODUCTION In our last research article (Mirror, Mirror on the(...) Slava Ukraini! Latest from Quantocracy contributor in Ukraine: Jupyter Notebook To Download VIX Futures [Only VIX]I will be publishing some of my research notebooks, starting with downloader for VIX data, fitting Nelson-Siegel model for term structure ( static ) , and dynamic ( Kalman Filter ), and possibly some recent work I did on regime clusters in VIX and ML for VIX trading. Here is the link to the first(...) Consumer Spending Data and the Cross-Section of Stock Returns [Alpha Architect]Consumer demand drives the cash flows of consumer-oriented companies. Thus, they should serve as a reliable source of information to predict future fundamentals above and beyond the information contained in financial statements and readily available market data. For example, Jiekun Huang, author of(...) Should Levered and Inverse ETFs Even Exist? [Alpha Architect]In 2019, the SEC proposed that all brokers and advisors be required to determine whether or not their clients understood the risks of investing in levered and inverse exchange traded products before selling such products to them. The SEC moved on this requirement in response to a series of fund(...) Living Our Mission [Quant Connect]We’re happy to share that today we published the code for 15 brokerage integrations to our open-source platform, LEAN. One step toward the future we’re building. LEAN handles all of the data and brokerage infrastructure for you so you can focus on what matters most: creating brilliant(...) Has the Stock Market Systematically Changed? [Alpha Architect]The past few years in the stock market have been pretty crazy. And the pinnacle of “crazy” was during March 2020 — peak chaos in the stock market. Below is a chart of US large-cap stocks and small-cap stocks in 2020. Note the monster crash in March — watch out below! Source: koyfin.com As an(...) Forecasting with Decision Trees and Random Forests [Sarem Seitz]Today, Deep Learning dominates many areas of modern machine learning. On the other hand, Decision Tree based models still shine particularly for tabular data. If you look up the winning solutions of respective Kaggle challenges, chances are high that a tree model is among them. A key advantage of(...) Hierarchical PCA x Hierarchical clustering on crypto perpetual futures [Gautier Marti]PCA is a useful tool for quant trading (stat arb) but in its naive implementation suffers from several forms of instabilities which yield to unnecessary turnover (trading cost…) and spurious trades. In order to regularize the model, several techniques are available: Sparse PCA Robust PCA Kernel(...) The Linear Regression-Adjusted Exponential Moving Average [Financial Hacker]There are already uncounted variants of moving averages. Vitali Apirine invented another one in his article in the Stocks&Commodities September issue. The LREMA is an EMA with a variable period derived from the distance of the current price and a linear regression line. This ensures an optimal(...) Crypto PCA First Eigenvector [Gautier Marti]This short blog to illustrate an interesting fact that I found in An Analysis of Eigenvectors of a Stock Market Cross-Correlation Matrix by Nguyen and co-authors: The first eigenvector is not THE market portfolio (market-cap or uniformly weighted) as people usually believe, but a(...) How Did Momentum Investing Perform After the Previous Two Valuation Peaks? [Alpha Architect]Near the end of 2021, I wrote an article noting that value portfolios looked historically cheap based on valuation spreads. I found that in the next five years (after the peak), Value investing performed quite well.(1) Following this post, I have received numerous questions related to the following(...) Cross-Asset Signals and Time Series Momentum [Allocate Smartly]This is a test of concepts from the paper Cross-Asset Signals and Time Series Momentum. Standard “time series” momentum is a well-documented feature of financial markets. Assets going up tend to continue going up. In this paper, the authors show that stocks and treasuries can be used to time(...) The Probabilistic Sharpe Ratio [Portfolio Optimizer]The Sharpe ratio1 is one of the most commonly used measure of financial portfolio performance, but because it is deeply rooted in mean-variance theory, its usage with return distributions deviating from normality (e.g. hedge funds, cryptocurrencies) is frequently questioned2. One solution to this(...) Three Factor ETF Rotation Strategy [Alvarez Quant Trading]I am drawn to ETF rotation strategies. What likely draws me to them is that in general, these are simple strategies that do not trade that often. My goal with these strategies is to match buy and hold with less drawdown. What follows is a strategy I have known about for a while and tested but never(...) Adversarial examples and quant quakes [Alex Chinco]Imagine you’re a quantitative long-short equities trader. If you can predict which stocks will have above-average returns next period and which will have below-average returns, then you can profit by buying the winners and selling short the losers. Return predictability and trading profits are two(...) The Short-Duration Equity Premium [Alpha Architect]The objective of research into asset pricing is to determine which characteristics are most important for predicting returns and then build simplified models using as few factors as possible—to tame the so-called “zoo of factors”—while still providing a high level of explanatory power. In(...) NEW Contributor: Multivariate GARCH with Python and Tensorflow [Sarem Seitz]In an earlier article, we discussed how to replace the conditional Gaussian assumption in a traditional GARCH model. While such gimmicks are a good start, they are far from being useful for actual applications. One primary limitation is the obvious restriction to a single dimensional time-series. In(...) Optimal Allocation to Cryptocurrencies in Diversified Portfolios [Artur Sepp]Cryptocurrencies have been acknowledged as an emerging asset class with a relatively low correlation to traditional asset classes. One of the most important questions for allocators is how much to allocate to Bitcoin and to a portfolios cryptocurrency assets within a broad portfolio which includes(...) Analyzing U.S. election cycle seasonality in the S&P 500 [Quant Dare]Everyone is aware of the importance of the U.S. elections and we take it for granted that, like many other things, financial markets will end up being affected in some way. But have you ever wondered if there is any seasonality throughout those elections that we can take advantage of when making(...)