Quant Mashup - Quintuitive
2018 Volatility Recap [Quintuitive]
2018 brought more volatility to the markets, which so far has spilled into 2019. Let’s take a look at the long term volatility history picture using the Dow Jones Industrial Average: Indeed, 2018 was the most volatile year since 2011. Relatively speaking however, the volatility is on the low end
- 4 years ago, 7 Jan 2019, 09:48am -
The Bear is Here [Quintuitive]
October and December have been devastating for stocks. It wasn’t until Friday though that we officially reached the depths of a bear market. There are different theories, the most common is 20% pullback in an index. As readers of this blog are aware, I follow a slightly different definition, based
- 4 years ago, 22 Dec 2018, 10:45pm -
Seasonalities: Bad Period for Stocks? [Quintuitive]
I just finished the implementation of another approach to finding repetitive calendar behaviour, and was quite surprised that the only short period for stocks, has just began. What are the odds of this?
- 4 years ago, 29 Jul 2018, 10:15am -
The Only Game in Town: @QuantConnect [Quintuitive]
At least in my town. Sometime back I kind of decided to use Quantopian as the backtesting platform of my choice. QuantConnect was a close second best. Now, a few months later, Quantopian has decided to end the live trading. No choice, but to go back to the second choice. QuantConnet has several
- 5 years ago, 11 Sep 2017, 09:37am -
Convolutional Neural Network for Time Series [Quintuitive]
Neural networks have been around for a while, but it’s fair to say that many successful practical applications use at least one convolutional layer. Naturally, convolutions make sense for time series, so I went and added a few to the Walk-Forward Analysis. To make the code easier to use, I ended
- 5 years ago, 14 Apr 2017, 09:15pm -
A Tensorflow Exercise [Quintuitive]
A previous post in this series, implemented the Walk Forward Loop on top of Microsoft’s CNTK. There was interest in a Google’s Tensorflow implementation, which seems to be the more popular framework in this domain, I decided to put what have already done with Tensorflow. The full source code is
- 5 years ago, 3 Apr 2017, 10:58am -
Deep Learning for the Walk-Forward Loop [Quintuitive]
In the previous posts in these series (here, here and here) I used conventional machine learning to forecast the trading opportunities. Lately however I have been trying to move more and more towards deep learning. My first attempt was to extend the walk-forward loop to support neural networks, the
- 6 years ago, 30 Jan 2017, 09:42am -
Walk-Forward Analysis for Multiple Series [Quintuitive]
The examples in the previous posts in this series (see here, and here and here) all use a single series, the 10 year daily history for the heating oil back-adjusted contract. A further extension is to try to learn patterns from multiple series. At each step of the walk-forward loop, we consider all
- 6 years ago, 19 Dec 2016, 08:16am -
Tradelib Developments [Quintuitive]
It has been a while since I posted about my back-testing framework – tradelib, nevertheless, I have been constantly improving it. Among the new features, the most prominent is the support for SQLite. SQLite is a standalone, single file database, thus, it’s much easier to get software up and
- 6 years ago, 18 Nov 2016, 08:54am -
The Walk-Forward Loop [Quintuitive]
The previous post described the high level architecture of a walk-forward forecasting for time series data. As a hands-on implementation – let’s apply a simple QDA classifier on the series discussed previously. First things first, most of the relevant code is available on GitHub. Although in
- 6 years ago, 9 Oct 2016, 01:58am -
Better Model Selection for Evolving Models [Quintuitive]
For quite some time now I have been using R’s caret package to choose the model for forecasting time series data. The approach is satisfactory as long as the model is not an evolving model (i.e. is not re-trained), or if it evolves rarely. If the model is re-trained often – the approach has
- 6 years ago, 26 Sep 2016, 02:08am -
Labeling Opportunities in Price Series with Python [Quintuitive]
My plans are to use Python for the rest of this series. The main reasons are algorithm related, but irrelevant for the time being, however, I decided to re-write some of the code I posted recently and I found the experience rather surprising. The experience was quite positive, but let me explain: I
- 6 years ago, 21 Sep 2016, 10:01am -
Forecasting Opportunities [Quintuitive]
The previous post in this series, showed a way to identify trading opportunities. The approach I implemented used time series daily data to identify good entry points in terms of risk-reward. The natural next step is to try to make use of these opportunities using machine learning. To refresh: the
- 6 years ago, 13 Sep 2016, 09:51pm -
Labeling Opportunities in Price Series [Quintuitive]
One approach to trading which has been puzzling me lately, is to sit and wait for opportunities. Sounds simplistic, but it is indeed different than, for instance, the asset allocation strategies. In order to be able to even attempt taking advantage of these opportunities, however, we must be able to
- 6 years ago, 15 Aug 2016, 01:23am -
Loading Data with Pandas [Quintuitive]
On at least a couple of occasions lately, I realized that I may need Python in the near future. While I have amassed some limited experience with the language over the years, I never spent the time to understand Pandas, its de-facto standard data-frame library. Where does one start? For me its
- 6 years ago, 28 Jun 2016, 10:35am -
Too Much Parallelism is as Bad [Quintuitive]
The other day I run a machine learning backtest on a new data set. Once I got through the LDA and QDA initial run, I decided to try xgboost. The first thing I observed was a really bad performance. The results from the following debugging session were quite surprising to me. I have been using the
- 6 years ago, 8 May 2016, 04:21am -
Volatility and Bollinger Bands [Quintuitive]
It is a common knowledge that Bollinger Bands (price standard deviation added to a moving average of the price) are an indicator for volatility. Expanding bands – higher volatility, squeezing bands – lower volatility. A bit of googling and you get the idea. In my opinion – that’s wrong,
- 6 years ago, 14 Feb 2016, 01:46pm -
Why is Tradelib in Java? [Quintuitive]
Why Java? Doesn't sound like a meaningful question at first - whatever works, right? Yes, but it's not that I didn't have a choice, and Java was hardly my first choice. There were at least a few other attractive options: C#, Python and Go. Lat but not least, don't forget, I am a
- 7 years ago, 24 Jan 2016, 11:12am -
Creating Calendars for Future's Expiration [Quintuitive]
R Futures Contact About Follow Follow on Facebook Follow on Twitter Follow on LinkedIn Follow on Google Follow Blogroll CSSA MarketSci Quantitative Trading Quantocracy Quantum Financier QUSMA R-bloggers Systematic Investor Creating Calendars for Future’s Expiration 2016-01-17 Lately I have been
- 7 years ago, 17 Jan 2016, 03:14am -
Is the Stock Market Different? [Quintuitive]
Overall, we expect the stock market to go higher. There is a good reason for that – the stock market is positive close to 54% of the days. A natural questions is whether this holds for other markets as well. There is inflation after all. Looks like the stock market is more or less unique in that
- 7 years ago, 23 Nov 2015, 12:33pm -
Trading Autocorrelation? [Quintuitive]
Markets are very smart in absorbing and reflecting information. If you think otherwise, try making money by trading. If you are new to it, make sure you don’t bet the house. In other words, markets are efficient. At least most of the time. So then why people trade? The general believe is that
- 7 years ago, 16 Nov 2015, 12:40am -
When is a Backtest Too Good to be True? Part Two [Quintuitive]
In the previous post, I went through a simple exercise which, to me, clearly demonsrtates that 60% out of sample guess rate (on daily basis) for S&P 500 will generate ridiculous returns. From the feedback I got, it seemed that my example was somewhat unconvincing. Let’s dig a bit further then.
- 7 years ago, 20 Sep 2015, 03:37am -
When is a Backtest Too Good to be True? [Quintuitive]
One statistic which I find useful to form a first impression of a backtest is the success/winning percentage. Since it can mean different things, let’s be more precise: for a strategy over daily data, the winning percentage is the percentage of the days on which the strategy had positive returns
- 7 years ago, 9 Sep 2015, 09:17pm -
Yahoo Finance Data Quirks. Or Why is the ROC not Stable? [Quintuitive]
Rotational strategies on ETFs have been a common occurrence on this blog, and I have been using something similar for real life trading for about two years now. Readers of this blog may have also noticed concerns about the stability of the computations of such strategies. At the end it turned out be
- 7 years ago, 1 Sep 2015, 01:06pm -
Tradelib is Open Source [Quintuitive]
Tradelib is my framework which I have been using for backtesting and signal generation in my futures trading. My feeling is that it might be useful to others, and I have decided to open source it. Unfortunately, I don’t have the time at the moment to open source any strategy implemented with it,
- 7 years ago, 10 Aug 2015, 08:22pm -
Trading Moving Averages with Less Whipsaws [Quintuitive]
Using a simple moving average to time markets has been a successful strategy over a very long period of time. Nothing to brag home about, but it cuts the drawdown of a buy and hold by about a half, sacrificing less than 1% of the CAGR in the process. In two words, simple yet effective. Here are the
- 7 years ago, 22 Jun 2015, 01:54am -
A Better ZigZag [Quintuitive]
There are a lot of “winning” strategies for bull markets floating around. “Buy the pullbacks” is certainly one of them. Does this sound simple enough to implement to you? While I am no Sheldon Cooper (although I have a favorite couch seat), I still like to live in a somewhat well defined
- 7 years ago, 6 Jun 2015, 02:25pm -
What has Worked in June [Quintuitive]
Time to start looking at the next month. Let’s start with the top five performing futures (ordered by winning percentage): Future Total Months Winning Months Mean Return Median Return 30-Year Bond 37 68% (25) 9.62% 1.57% Canadian Dollar 37 68% (25) 0.07% 0.53% 10-Year Note 32 63% (20) 9.46% 1.45%
- 7 years ago, 28 May 2015, 04:55pm -
Moved Quantscript to GitHub [Quintuitive]
Quantscript is an old project of mine, which was hosted on google.code. Since google.code is shutting down, I had to either scrap it or migrate it to GitHub. I am not using this code on a daily basis anymore, and since the project is relatively small – the natural thing would have been to scrap
- 7 years ago, 28 May 2015, 01:40am -
What has Worked in March? [Quintuitive]
Since February didn’t show anything interesting in the calendar analysis, I passed on writing a post about it. March, on the other hand, looks quite interesting. Let’s start with the top five performers (ordered by winning percentage): Future Total Months Winning Months Mean Return Median Return
- 7 years ago, 1 Mar 2015, 09:38pm -