Blog Archives

Simulation and relative performance

March 24, 2015
By
Simulation and relative performance

There’s been some nice posts on randomness the last week or so, in particular here and here. I would like to look at how we can use simulations to get a better understanding of how some aspect of a trading system holds up relative to a bunch of random trades.In this example, I look at entries on...

Read more »

Adopting R for experienced developers

March 14, 2015
By
Adopting R for experienced developers

More and more frequently I come across people who express an interest in R, and I thought I would share some advice to help people decide if R is something they should use, as well as some high level advice on getting started. Most of these people are developers with at least few years experience writing code...

Read more »

The R documentation is bad

March 6, 2015
By

I have been using R for some time now and still can find it frustrating to work with. Over the years have come to the conclusion that it is primarily due to the documentation being bad. I offer no actual solutions here, but thought I would try and write down exactly what I dislike about it.The docs are more...

Read more »

Fitting a mixture of independent Poisson distributions

December 26, 2014
By
Fitting a mixture of independent Poisson distributions

This is an example from Zucchini & MacDonald’s book on Hidden Markov Models for Time Series (exercise 1.3). The data is annual counts of earthquakes of magnitude 7 or greater, which exhibits both overdispersion for a Poisson (where the mean should equal the variance) as well as serial dependence. The aim is to fit a mixture of...

Read more »

Does Trend Following Work?

December 23, 2014
By
Does Trend Following Work?

I’m not sure how I came across it, but I have had Jez Liberty’s Au.Tra.Sy blog in my reader since around 2009. Since then, he has tracked well-known trend following systems and reported monthly performance figures. These are things like moving average crossovers, Bollinger band breakouts and stuff like that.The systems had a very good month...

Read more »

HMM example with depmixS4

September 21, 2014
By
HMM example with depmixS4

On a scale of one to straight up voodoo, Hidden Markov Models (HMMs) are definitely up there for me.They have all sorts of applications, and as the name suggests, they can be very useful when you wish to use a Markovian approach to represent some stochastic process.In loose terms this just means we wish to represent our process as...

Read more »

Bayesian Naive Bayes for Classification with the Dirichlet Distribution

July 14, 2014
By

I have a classification task and was reading up on various approaches. In the specific case where all inputs are categorical, one can use “Bayesian Naïve Bayes” using the Dirichlet distribution.  Poking through the freely available text by Barber, I found a rather detailed discussion in chapters 9 and 10, as well as example matlab code for the...

Read more »

Trading in a low vol world

June 22, 2014
By
Trading in a low vol world

I wanted to take a look at what works in low vol environments, such as we are currently experiencing. I am open to the idea we have entered a period of structurally low volatility due to increased regulatory burden and flow on effects from the dec...

Read more »

A quick look at FX realized vol

May 31, 2014
By
A quick look at FX realized vol

Much has been said about the decline in volatility. At the moment I am very active in FX spot trading and as a generalization do better the more vol there is. I wanted to see how things stood on the crosses I am most active in, namely EUR/USD, GBP/USD and USD/JPY. I took hourly data from FxPro (not my broker, nor...

Read more »

RcppArmadillo cheatsheet

May 17, 2014
By

I have been using RcppArmadillo more and more frequently, so thought I would make a cheatsheet/cookbook type reference that translates common R operations into equivalent arma code.I have put them up on a github wiki page here.The functions are al...

Read more »