<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>QUANTITATIVE RESEARCH AND TRADING</title>
	<atom:link href="http://jonathankinlay.com/index.php/feed/" rel="self" type="application/rss+xml" />
	<link>http://jonathankinlay.com</link>
	<description>The latest theories, models and investment strategies in quantitative research and trading</description>
	<lastBuildDate>Mon, 26 Sep 2011 11:24:20 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Measuring Toxic Flow for Trading &amp; Risk Management</title>
		<link>http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/</link>
		<comments>http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/#comments</comments>
		<pubDate>Mon, 19 Sep 2011 00:23:06 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Algorithmic Trading]]></category>
		<category><![CDATA[ARMA]]></category>
		<category><![CDATA[Direction Prediction]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[Econophysics]]></category>
		<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[High Frequency Finance]]></category>
		<category><![CDATA[Market Microstructure]]></category>
		<category><![CDATA[Order Flow]]></category>
		<category><![CDATA[Risk Management]]></category>
		<category><![CDATA[Time Series Modeling]]></category>
		<category><![CDATA[Toxic Flow]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=459</guid>
		<description><![CDATA[A common theme of microstructure modeling is that trade flow is often predictive of market direction.  One concept in particular that has gained traction is flow toxicity, i.e. flow where resting orders tend to be filled more quickly than expected, while aggressive orders rarely get filled at all, due to the participation of informed traders trading...]]></description>
			<content:encoded><![CDATA[<p>A common theme of microstructure modeling is that trade flow is often predictive of market direction.  One concept in particular that has gained traction is flow toxicity, i.e. flow where resting orders tend to be filled more quickly than expected, while aggressive orders rarely get filled at all, due to the participation of informed traders trading against uninformed traders.  The fundamental insight from microstructure research is that the order arrival process is informative of subsequent price moves in general and toxic flow in particular.  This is turn has led researchers to try to measure the probability of informed trading  (PIN).  One recent attempt to model flow toxicity, the Volume-Synchronized Probability of Informed Trading (VPIN)metric, seeks to estimate PIN based on volume imbalance and trade intensity.  A major advantage of this approach is that it does not require the estimation of unobservable parameters and, additionally, updating VPIN in trade time rather than clock time improves its predictive power.  VPIN has potential applications both in high frequency trading strategies, but also in risk management, since highly toxic flow is likely to lead to the withdrawal of liquidity providers, setting up the conditions for a flash-crash” type of market breakdown.</p>
<p>The procedure for estimating VPIN is as follows.  We begin by grouping sequential trades into equal volume buckets of size V.  If the last trade needed to complete a bucket was for a size greater than needed, the excess size is given to the next bucket.  Then we classify trades within each bucket into two volume groups:  Buys (V(t)<sub>B</sub>) and Sells (V(t)<sub>S</sub>), with V = V(t)<sub>B </sub>+ V(t)<sub>S</sub><br />
The Volume-Synchronized Probability of Informed Trading is then derived as:</p>
<p><a href="http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/vpin-2/" rel="attachment wp-att-465"><img class="aligncenter size-full wp-image-465" title="VPIN" src="http://jonathankinlay.com/wp-content/uploads/VPIN.png" alt="" width="750" height="66" /></a></p>
<p>Typically one might choose to estimate VPIN using a moving average over n buckets, with n being in the range of 50 to 100.</p>
<p>Another related statistic of interest is the single-period signed VPIN. This will take a value of between -1 and =1, depending on the proportion of buying to selling during a single period t.</p>
<p><a href="http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/single-period-vpin/" rel="attachment wp-att-466"><img class="aligncenter size-medium wp-image-466" title="Single Period VPIN" src="http://jonathankinlay.com/wp-content/uploads/Single-Period-VPIN-300x225.png" alt="" width="300" height="225" /></a></p>
<p style="text-align: center;">Fig 1. Single-Period Signed VPIN for the ES Futures Contract</p>
<p style="text-align: left;">It turns out that quote revisions condition strongly on the signed VPIN. For example, in tests of the ES futures contract, we found that the change in the midprice from one volume bucket the next  was highly correlated to the prior bucket’s signed VPIN, with a coefficient of 0.5.  In other words, market participants offering liquidity will adjust their quotes in a way that directly reflects the direction and intensity of toxic flow, which is perhaps hardly surprising.</p>
<p>Of greater interest is the finding that there is a small but statistically significant dependency of price changes, as measured by first buy (sell) trade price to last sell (buy) trade price, on the prior period’s signed VPIN.  The correlation is positive, meaning that strongly toxic flow in one direction has a tendency  to push prices in the same direction during the subsequent period. Moreover, the single period signed VPIN turns out to be somewhat predictable, since its autocorrelations are statistically significant at two or more lags.  A simple linear auto-regression ARMMA(2,1) model produces an R-square of around 7%, which is small, but statistically significant.</p>
<p>A more useful model, however , can be constructed by introducing the idea of Markov states and allowing the regression model to assume different parameter values (and error variances) in each state.  In the Markov-state framework, the system transitions from one state to another with conditional probabilities that are estimated in the model.</p>
<p>An example of such a model  for the signed VPIN in ES is shown below. Note that the model R-square is over 27%, around 4x larger than for a standard linear ARMA model.</p>
<p>We can describe the regime-switching model in the following terms.  In the regime 1 state  the model has two significant autoregressive terms and one significant moving average term (ARMA(2,1)).  The AR1 term is large and positive, suggesting that trends in VPIN tend to be reinforced from one period to the next. In other words, this is a momentum state. In the regime 2 state the AR2 term is not significant and the AR1 term is large and negative, suggesting that changes in VPIN in one period tend to be reversed in the following period, i.e. this is a mean-reversion state.</p>
<p>The state transition probabilities indicate that the system is in mean-reversion mode for the majority of the time, approximately around 2 periods out of 3.  During these periods, excessive flow in one direction during one period tends to be corrected in the<br />
ensuring period.  But in the less frequently occurring state 1, excess flow in one direction tends to produce even more flow in the same direction in the following period.  This first state, then, may be regarded as the regime characterized by toxic flow.</p>
<p><strong><span style="text-decoration: underline;">Markov State Regime-Switching Model</span></strong></p>
<p>Markov Transition Probabilities</p>
<p>P(.|1)       P(.|2)</p>
<p>P(1|.)        0.54916      0.27782</p>
<p>P(2|.)       0.45084      0.7221</p>
<p>Regime 1:</p>
<p>AR1           1.35502    0.02657   50.998        0</p>
<p>AR2         -0.33687    0.02354   -14.311        0</p>
<p>MA1          0.83662    0.01679   49.828        0</p>
<p>Error Variance^(1/2)           0.36294     0.0058</p>
<p>Regime 2:</p>
<p>AR1      -0.68268    0.08479    -8.051        0</p>
<p>AR2       0.00548    0.01854    0.296    0.767</p>
<p>MA1     -0.70513    0.08436    -8.359        0</p>
<p>Error Variance^(1/2)           0.42281     0.0016</p>
<p>Log Likelihood = -33390.6</p>
<p>Schwarz Criterion = -33445.7</p>
<p>Hannan-Quinn Criterion = -33414.6</p>
<p>Akaike Criterion = -33400.6</p>
<p>Sum of Squares = 8955.38</p>
<p>R-Squared =  0.2753</p>
<p>R-Bar-Squared =  0.2752</p>
<p>Residual SD =  0.3847</p>
<p>Residual Skewness = -0.0194</p>
<p>Residual Kurtosis =  2.5332</p>
<p>Jarque-Bera Test = 553.472     {0}</p>
<p>Box-Pierce (residuals):         Q(9) = 13.9395 {0.124}</p>
<p>Box-Pierce (squared residuals): Q(12) = 743.161     {0}</p>
<p>&nbsp;</p>
<p><strong><span style="text-decoration: underline;">A Simple Trading Strategy</span></strong></p>
<p>One way to try to monetize the predictability of the VPIN model is to use the forecasts to take directional positions in the ES<br />
contract.  In this simple simulation we assume that we enter a long (short) position at the first buy (sell) price if the forecast VPIN exceeds some threshold value 0.1  (-0.1).  The simulation assumes that we exit the position at the end of the current volume bucket, at the last sell (buy) trade price in the bucket.</p>
<p>This simple strategy made 1024 trades over a 5-day period from 8/8 to 8/14, 90% of which were profitable, for a total of $7,675 – i.e. around ½ tick per trade.</p>
<p>The simulation is, of course, unrealistically simplistic, but it does give an indication of the prospects for  more realistic version of the strategy in which, for example, we might rest an order on one side of the book, depending on our VPIN forecast.</p>
<p><a href="http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/pl/" rel="attachment wp-att-467"><img class="aligncenter size-medium wp-image-467" title="Trade PL" src="http://jonathankinlay.com/wp-content/uploads/PL-300x225.png" alt="" width="300" height="225" /></a></p>
<p style="text-align: center;">Figure 2 – Cumulative Trade PL</p>
<p><strong><span style="text-decoration: underline;">References</span></strong></p>
<p>Easley, D., Lopez de Prado, M., O’Hara, M., Flow Toxicity and Volatility in a High frequency World, Johnson School Research paper Series # 09-2011, 2011</p>
<p>Easley, D. and M. O‟Hara (1987), &#8220;Price, Trade Size, and Information in Securities Markets&#8221;, Journal of Financial Economics, 19.</p>
<p>Easley, D. and M. O‟Hara (1992a), <em>&#8220;Adverse Selection and Large Trade Volume: The Implications for Market Efficiency&#8221;</em>,<br />
Journal of Financial and Quantitative Analysis, 27(2), June, 185-208.</p>
<p>Easley, D. and M. O‟Hara (1992b), <em>“Time and the process of security price adjustment”</em>, Journal of Finance, 47, 576-605.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/09/measuring-toxic-flow-for-trading-risk-management/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Generalized Regression</title>
		<link>http://jonathankinlay.com/index.php/2011/06/generalized-regression/</link>
		<comments>http://jonathankinlay.com/index.php/2011/06/generalized-regression/#comments</comments>
		<pubDate>Sun, 05 Jun 2011 17:34:10 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Financial Engineering]]></category>
		<category><![CDATA[Regression]]></category>
		<category><![CDATA[Financial engineering]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=446</guid>
		<description><![CDATA[Linear regression is one of the most useful applications in the financial engineer&#8217;s tool-kit, but it suffers from a rather restrictive set of assumptions that limit its applicability in areas of research that are characterized by their focus on highly non-linear or correlated variables.  The latter problem, referred to as colinearity (or multicolinearity) arises very...]]></description>
			<content:encoded><![CDATA[<p><a href="http://en.wikipedia.org/wiki/Linear_regression" target="_blank">Linear regression</a> is one of the most useful applications in the financial engineer&#8217;s tool-kit, but it suffers from a rather restrictive set of assumptions that limit its applicability in areas of research that are characterized by their focus on highly non-linear or correlated variables.  The latter problem, referred to as colinearity (or <a href="http://en.wikipedia.org/wiki/Multicollinearity" target="_blank">multicolinearity</a>) arises very frequently in financial research, because asset processes are often somewhat (or even highly) correlated.  In a colinear system, one can test for the overall significant of the regression relationship, but one is unable to distinguish which of the explanatory variables is individually significant.  Furthermore, the estimates of the model paramaters, the weights applied to each explanatory variable, tend to be biased.</p>
<p>Over time, many attempts have been made to address this issue, one well-known example being ridge regression.  More recent attempts include lasso, elastic net and what I term generalized regression, which appear to offer significant advantages vs traditional regression techniques in situations where the variables are correlated.</p>
<p>In this note, I examine a variety of these technqiues and attempt to illustrate and compare their effectiveness.</p>
<p><a rel="attachment wp-att-451" href="http://jonathankinlay.com/index.php/2011/06/generalized-regression/generalized-regression-graphic-3/"><img class="aligncenter size-medium wp-image-451" title="Generalized Regression Graphic" src="http://jonathankinlay.com/wp-content/uploads/Generalized-Regression-Graphic2-300x191.jpg" alt="" width="300" height="191" /></a></p>
<p>You can downlaod a <a title="Generalized Regression pdf" href="http://www.jonathankinlay.com/Articles/Generalized%20Regression/Generalized%20Regression.pdf" target="_blank">pdf </a>here.</p>
<p>A <em>Mathematica </em>notebook is also available <a href="http://www.jonathankinlay.com/Articles/Generalized%20Regression/Generalized%20Regression.nb">here</a>.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/06/generalized-regression/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Hiring High Frequency Quant/Traders</title>
		<link>http://jonathankinlay.com/index.php/2011/05/hiring-quanttraders/</link>
		<comments>http://jonathankinlay.com/index.php/2011/05/hiring-quanttraders/#comments</comments>
		<pubDate>Thu, 26 May 2011 18:29:52 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[High Frequency Finance]]></category>
		<category><![CDATA[High Frequency Trading]]></category>
		<category><![CDATA[Jobs]]></category>
		<category><![CDATA[Quant/Traders]]></category>
		<category><![CDATA[Recruitment]]></category>
		<category><![CDATA[Chicago]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=437</guid>
		<description><![CDATA[I am hiring in Chicago for exceptional HF Quant/Traders in Equities, F/X, Futures &#38; Fixed Income.  Remuneration for these roles, which will be dependent on qualifications and experience, will be in line with the highest market levels. Role Working closely with team members including developers, traders and quantitative researchers, the central focus of the role will be...]]></description>
			<content:encoded><![CDATA[<p>I am hiring in Chicago for exceptional HF Quant/Traders in Equities, F/X, Futures &amp; Fixed Income.  Remuneration for these roles, which will be dependent on qualifications and experience, will be in line with the highest market levels.</p>
<p><strong>Role<br />
</strong>Working closely with team members including developers, traders and quantitative researchers, the central focus of the role will be to research and develop high frequency trading strategies in equities, fixed income, foreign exchange and related commodities markets.</p>
<p><strong>Responsibilities</strong><br />
The analyst will have responsibility of taking an idea from initial conception through research, testing and implementation.  The work will entail:</p>
<ul>
<li>Formulation of mathematical and econometric models for market microstructure</li>
<li>Data collation, normalization and analysis</li>
<li>Model prototyping and programming</li>
<li>Strategy development, simulation, back-testing and implementation</li>
<li>Execution strategy &amp; algorithms</li>
</ul>
<p><strong>Qualifications &amp; Experience</strong></p>
<ul>
<li>Minimum 5 years in quantitative research with a leading proprietary trading firm, hedge fund, or investment bank</li>
<li>In-depth knowledge of Equities, F/X and/or futures markets, products and operational infrastructure</li>
<li>High frequency data management &amp; data mining techniques</li>
<li>Microstructure modeling</li>
<li>High frequency econometrics (cointegration, VAR,error correction models, GARCH, panel data models, etc.)</li>
<li>Machine learning, signal processing, state space modeling and pattern recognition</li>
<li>Trade execution and algorithmic trading</li>
<li>PhD in Physics/Math/Engineering, Finance/Economics/Statistics</li>
<li>Expert programming skills in Java, Matlab/Mathematica essential</li>
<li><strong>Must be US Citizen or Permanent Resident</strong></li>
</ul>
<p>Send your resume to: jkinlay at systematic-strategies.com.</p>
<p>No recruiters please.</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/05/hiring-quanttraders/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Alpha Spectral Analysis</title>
		<link>http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/</link>
		<comments>http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/#comments</comments>
		<pubDate>Sun, 22 May 2011 23:56:14 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[Fourier Transforms]]></category>
		<category><![CDATA[High Frequency Finance]]></category>
		<category><![CDATA[Pairs Trading]]></category>
		<category><![CDATA[Principal Components Analysis]]></category>
		<category><![CDATA[Signal Processing]]></category>
		<category><![CDATA[Statistical Arbitrage]]></category>
		<category><![CDATA[High Frequency Trading]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=412</guid>
		<description><![CDATA[One of the questions of interest is the optimal sampling frequency to use for extracting the alpha signal from an alpha generation function.  We can use Fourier transforms to help identify the cyclical behavior of the strategy alpha and hence determine the best time-frames for sampling and trading.  Typically, these spectral analysis techniques will highlight...]]></description>
			<content:encoded><![CDATA[<p>One of the questions of interest is the optimal sampling frequency to use for extracting the alpha signal from an alpha generation function.  We can use Fourier transforms to help identify the cyclical behavior of the strategy alpha and hence determine the best time-frames for sampling and trading.  Typically, these spectral analysis techniques will highlight several different cycle lengths where the alpha signal is strongest.</p>
<p>The spectral density of the combined alpha signals across twelve pairs of stocks is shown in Fig. 1 below.  It is clear that the strongest signals occur in the shorter frequencies with cycles of up to several hundred seconds. Focusing on the density within<br />
this time frame, we can identify in Fig. 2 several frequency cycles where the alpha signal appears strongest. These are around 50, 80, 160, 190, and 230 seconds.  The cycle with the strongest signal appears to be around 228 secs, as illustrated in Fig. 3.  The signals at cycles of 54 &amp; 80 (Fig. 4), and 158 &amp; 185/195 (Fig. 5) secs appear to be of approximately equal strength.<br />
There is some variation in the individual pattern for of the  power spectra for each pair, but the findings are broadly comparable, and  indicate that strategies should be designed for sampling frequencies at around  these time intervals.</p>
<dl id="attachment_414">
<dt><a rel="attachment wp-att-414" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-1/"></a></dt>
<dd></dd>
<dd><a rel="attachment wp-att-414" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-1/"><img class="aligncenter" title="Fig 1" src="http://jonathankinlay.com/wp-content/uploads/Fig-1-300x225.jpg" alt="" width="300" height="225" /></a></dd>
</dl>
<p style="text-align: center;">Fig. 1 Alpha Power Spectrum</p>
<p>&nbsp;</p>
<p><a rel="attachment wp-att-415" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-2/"><img class="aligncenter size-medium wp-image-415" title="Fig 2" src="http://jonathankinlay.com/wp-content/uploads/Fig-2-300x225.jpg" alt="" width="300" height="225" /></a></p>
<p style="text-align: center;">Fig.2</p>
<p style="text-align: center;"><a rel="attachment wp-att-416" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-3/"><img class="aligncenter size-medium wp-image-416" title="Fig 3" src="http://jonathankinlay.com/wp-content/uploads/Fig-3-300x225.jpg" alt="" width="300" height="225" /></a>Fig. 3</p>
<p style="text-align: center;"><a rel="attachment wp-att-417" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-4/"><img class="aligncenter size-medium wp-image-417" title="Fig 4" src="http://jonathankinlay.com/wp-content/uploads/Fig-4-300x225.jpg" alt="" width="300" height="225" /></a>Fig. 4</p>
<p style="text-align: center;"><a rel="attachment wp-att-418" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-5/"><img class="aligncenter size-medium wp-image-418" title="Fig 5" src="http://jonathankinlay.com/wp-content/uploads/Fig-5-300x225.jpg" alt="" width="300" height="225" /></a>Fig. 5</p>
<p><strong>PRINCIPAL COMPONENTS ANALYSIS OF ALPHA POWER SPECTRUM</strong><br />
If we look at the correlation surface of the power spectra of the twelve pairs some clear patterns emerge (see Fig 6):</p>
<p style="text-align: center;"><a rel="attachment wp-att-421" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-6/"><img class="aligncenter size-full wp-image-421" title="Fig 6" src="http://jonathankinlay.com/wp-content/uploads/Fig-6.jpg" alt="" width="605" height="380" /></a>Fig. 6</p>
<p>Focusing on the off-diagonal elements, it is clear that the power spectrum of each pair is perfectly correlated with the power spectrum of its conjugate.   So, for instance the power spectrum of the Stock1-Stock3 pair is exactly correlated with the spectrum for its converse, Stock3-Stock1.</p>
<p>But it is also clear that there are many other significant correlations between non-conjugate pairs.  For example, the correlation between the power spectra for Stock1-Stock2 vs Stock2-Stock3 is 0.72, while the correlation of the power spectra of Stock1-Stock2 and Stock2-Stock4 is 0.69.</p>
<p>We can further analyze the alpha power spectrum using PCA to expose the underlying factor structure.  As shown in Fig. 7, the first two principal components account for around 87% of the variance in the alpha power spectrum, and the first four components account for over 98% of the total variation.</p>
<div id="attachment_422" class="wp-caption aligncenter" style="width: 310px"><a rel="attachment wp-att-422" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-7/"><img class="size-medium wp-image-422" title="Fig 7" src="http://jonathankinlay.com/wp-content/uploads/Fig-7-300x225.jpg" alt="" width="300" height="225" /></a><p class="wp-caption-text">PCA Analysis of Power Spectra</p></div>
<p style="text-align: center;">Fig. 7</p>
<p>Stock3 dominates PC-1 with loadings of 0.52 for Stock3-Stock4, 0.64 for Stock3-Stock2, 0.29 for Stock1-Stock3 and 0.26 for Stock4-Stock3.  Stock3 is also highly influential in PC-2 with loadings of -0.64 for Stock3-Stock4 and 0.67 for Stock3-Stock2 and again in PC-3 with a loading of -0.60 for Stock3-Stock1.  Stock4 plays a major role in the makeup of PC-3, with the highest loading of 0.74 for Stock4-Stock2.</p>
<p><a rel="attachment wp-att-423" href="http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/fig-8/"><img class="aligncenter size-full wp-image-423" title="Fig 8" src="http://jonathankinlay.com/wp-content/uploads/Fig-8.jpg" alt="" width="725" height="533" /></a></p>
<p style="text-align: center;">Fig. 8  PCA Analysis of Power Spectra</p>
<p style="text-align: center;">&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/05/alpha-spectral-analysis/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Market Microstructure Models for High Frequency Trading Strategies</title>
		<link>http://jonathankinlay.com/index.php/2011/05/market-microstructure-models-for-high-frequency-trading-strategies/</link>
		<comments>http://jonathankinlay.com/index.php/2011/05/market-microstructure-models-for-high-frequency-trading-strategies/#comments</comments>
		<pubDate>Sun, 08 May 2011 16:12:01 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Econophysics]]></category>
		<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[High Frequency Finance]]></category>
		<category><![CDATA[High Frequency Trading]]></category>
		<category><![CDATA[Market Microstructure]]></category>
		<category><![CDATA[High Frequency Finanance]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=408</guid>
		<description><![CDATA[This note summarizes some of the key research in the field of market microstructure and considers some of the models proposed by the researchers. Many of the ideas presented here have become widely adopted by high frequency trading firms and incorporated into their trading systems.]]></description>
			<content:encoded><![CDATA[<p><span style="color: #000080; font-family: Times New Roman;"><span style="color: #000080; font-family: Times New Roman;"><a title="Market Microstructure Models" href="http://www.Jonathankinlay.com/Articles/Market%20Microstructure%20Models/Market%20MicroStructure%20Models.pdf" target="_blank">This note </a>summarizes some of the key research in the field of market microstructure and considers some of the models proposed by the researchers. Many of the ideas presented here have become widely adopted by high frequency trading firms and incorporated into their trading systems.</span></span></p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/05/market-microstructure-models-for-high-frequency-trading-strategies/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Forecasting Financial Markets &#8211; Part 1:  Time Series Analysis</title>
		<link>http://jonathankinlay.com/index.php/2011/04/forecasting-financial-markets-part-1-time-series-analysis/</link>
		<comments>http://jonathankinlay.com/index.php/2011/04/forecasting-financial-markets-part-1-time-series-analysis/#comments</comments>
		<pubDate>Sat, 30 Apr 2011 10:45:47 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[ARMA]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[Purchasing Power Parity]]></category>
		<category><![CDATA[Time Series Modeling]]></category>
		<category><![CDATA[Unit Roots]]></category>
		<category><![CDATA[White Noise]]></category>
		<category><![CDATA[ARMA Models]]></category>
		<category><![CDATA[Box Jenkins]]></category>
		<category><![CDATA[Direction Prediction]]></category>
		<category><![CDATA[Time Series Analysis]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=392</guid>
		<description><![CDATA[The presentation in this post covers a number of important topics in forecasting, including: Stationary processes and random walks Unit roots and autocorrelation ARMA models Seasonality Model testing Forecasting Dickey-Fuller and Phillips-Perron tests for unit roots Also included are a number of detailed worked examples, including: ARMA Modeling Box Jenkins methodology Modeling the US Wholesale Price...]]></description>
			<content:encoded><![CDATA[<p>The <a title="Forecasting Financial Markets - Time Series Analysis" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Forecasting%202011%20-%20Time%20Series.pdf" target="_blank">presentation </a> in this post covers a number of important topics in forecasting, including:</p>
<ul>
<li>Stationary processes and random walks</li>
<li>Unit roots and autocorrelation</li>
<li>ARMA models</li>
<li>Seasonality</li>
<li>Model testing</li>
<li>Forecasting</li>
<li>Dickey-Fuller and Phillips-Perron tests for unit roots</li>
</ul>
<p>Also included are a number of detailed worked examples, including:</p>
<ol>
<li><a title="ARMA Modeling" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Arma11.pdf" target="_blank">ARMA Modeling</a></li>
<li><a title="Box Jenkins" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Box-Jenkins%20Analysis.PDF" target="_blank">Box Jenkins methodology</a></li>
<li><a title="Wholesale Price Index" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Wpi.pdf" target="_blank">Modeling the US Wholesale Price Index</a></li>
<li><a title="Pesaran Timmermann Study" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Recursive%20Regression%20Prediction%20of%20Equity%20Returns.PDF" target="_blank">Pesaran &amp; Timmermann study of excess equity returns</a></li>
<li><a title="Purchasing Power Parity" href="http://www.jonathankinlay.com/Articles/Part%201%20-%20Time%20Series%20Analysis/Purchasing%20Power%20Parity.PDF" target="_blank">Purchasing Power Parity</a></li>
</ol>
<ul></ul>
<p><a rel="attachment wp-att-402" href="http://jonathankinlay.com/index.php/2011/04/forecasting-financial-markets-part-1-time-series-analysis/rolling-regression/"><img class="aligncenter size-full wp-image-402" title="Rolling Regression" src="http://jonathankinlay.com/wp-content/uploads/Rolling-Regression.jpg" alt="" width="750" height="479" /></a><a rel="attachment wp-att-402" href="http://jonathankinlay.com/index.php/2011/04/forecasting-financial-markets-part-1-time-series-analysis/rolling-regression/"></a></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/04/forecasting-financial-markets-part-1-time-series-analysis/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Master&#8217;s in High Frequency Finance</title>
		<link>http://jonathankinlay.com/index.php/2011/04/masters-in-high-frequency-finance/</link>
		<comments>http://jonathankinlay.com/index.php/2011/04/masters-in-high-frequency-finance/#comments</comments>
		<pubDate>Wed, 27 Apr 2011 11:27:44 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Algorithmic Trading]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[Education]]></category>
		<category><![CDATA[Financial Engineering]]></category>
		<category><![CDATA[Graduate Programs]]></category>
		<category><![CDATA[High Frequency Finance]]></category>
		<category><![CDATA[High Frequency Trading]]></category>
		<category><![CDATA[Market Microstructure]]></category>
		<category><![CDATA[Financial engineering]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=375</guid>
		<description><![CDATA[I have been discussing with some potential academic partners the concept for a new graduate program in High Frequency Finance.  The idea is to take the concept of the Computational Finance program developed in the 1990s and update it to meet the needs of students in the 2010s. The program will offer a thorough grounding...]]></description>
			<content:encoded><![CDATA[<p>I have been discussing with some potential academic partners the concept for a new graduate program in High Frequency Finance.  The idea is to take the concept of the Computational Finance program developed in the 1990s and update it to meet the needs of students in the 2010s.</p>
<p>The program will offer a thorough grounding in the modeling concepts, trading strategies and risk management procedures currently in use by leading investment banks, proprietary trading firms and hedge funds in US and international financial markets.  Students will also learn the necessary programming and systems design skills to enable them to make an effective contribution as quantitative analysts, traders, risk managers and developers.</p>
<p>I would be interested in feedback and suggestions as to the proposed content of <a title="Master's in High Frequency Finance" href="http://www.jonathankinlay.com/Articles/MSc%20in%20High%20Frequency%20Finance.pdf" target="_blank">the program</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/04/masters-in-high-frequency-finance/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>A Practical Application of Regime Switching Models to Pairs Trading</title>
		<link>http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/</link>
		<comments>http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/#comments</comments>
		<pubDate>Sun, 24 Apr 2011 11:56:22 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[ARMA]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[ETFs]]></category>
		<category><![CDATA[Markov Model]]></category>
		<category><![CDATA[Mean Reversion]]></category>
		<category><![CDATA[Pairs Trading]]></category>
		<category><![CDATA[Regime Switching]]></category>
		<category><![CDATA[Statistical Arbitrage]]></category>
		<category><![CDATA[Kalman Filter]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=344</guid>
		<description><![CDATA[In the previous post I outlined some of the available techniques used for modeling market states.  The following is an illustration of how these techniques can be applied in practice.    You can download this post in pdf format here. The chart below shows the daily compounded returns for a single pair in an ETF statistical arbitrage...]]></description>
			<content:encoded><![CDATA[<p>In the previous post I outlined some of the available techniques used for modeling market  states.  The following is an illustration of how these techniques can be applied in practice.    You can download this post in pdf format <a title="Article on Market State Models" href="http://www.jonathankinlay.com/Articles/FOLLOW%20UP%20NOTE%20ON%20MARKET%20STATE%20MODELS.pdf" target="_blank">here</a>.</p>
<p>The chart below shows the daily compounded returns for a single pair in an ETF statistical arbitrage strategy, back-tested over a 1-year period from April 2010 to March 2011.</p>
<p>The idea is to examine the characteristics of the returns process and assess its predictability.</p>
<p><a rel="attachment wp-att-346" href="http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/pair6/"><img class="aligncenter size-medium wp-image-346" title="Pair6" src="http://jonathankinlay.com/wp-content/uploads/Pair6-300x172.jpg" alt="" width="433" height="266" /></a></p>
<p>The initial impression given by the analytics plots of daily returns, shown in Fig 2 below, is that the process may be somewhat predictable, given what appears to be a significant 1-order lag in the autocorrelation spectrum.  We also see evidence of the<br />
customary non-Gaussian “fat-tailed” distribution in the error process.</p>
<p><a rel="attachment wp-att-349" href="http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/analytical-plots/"><img class="aligncenter size-medium wp-image-349" title="Analytical Plots" src="http://jonathankinlay.com/wp-content/uploads/Analytical-Plots-300x172.jpg" alt="" width="614" height="398" /></a></p>
<p>An initial attempt to fit a standard Auto-Regressive Moving Average ARMA(1,0,1) model  yields disappointing results, with an unadjusted  model R-squared of only 7% (see model output in Appendix 1)</p>
<p>However, by fitting a 2-state Markov model we are able to explain as much as 65% in the variation in the returns process (see Appendix II).<br />
The model estimates Markov Transition Probabilities as follows.</p>
<p>P(.|1)       P(.|2)</p>
<p>P(1|.)       0.93920      0.69781</p>
<p>P(2|.)     0.060802      0.30219</p>
<p>In other words, the process spends most of the time in State 1, switching to State 2 around once a month, as illustrated in Fig 3 below.</p>
<p><a rel="attachment wp-att-350" href="http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/state-probs/"><img class="aligncenter size-medium wp-image-350" title="State Probs" src="http://jonathankinlay.com/wp-content/uploads/State-Probs-300x172.jpg" alt="" width="300" height="172" /></a><br />
In the first state, the  pairs model produces an expected daily return of around 65bp, with a standard deviation of similar magnitude.  In this state, the process also exhibits very significant auto-regressive and moving average features.</p>
<p>Regime 1:</p>
<p>Intercept                   0.00648     0.0009       7.2          0</p>
<p>AR1                            0.92569    0.01897   48.797        0</p>
<p>MA1                         -0.96264    0.02111   -45.601        0</p>
<p>Error Variance^(1/2)           0.00666     0.0007</p>
<p>In the second state, the pairs model  produces lower average returns, and with much greater variability, while the autoregressive and moving average terms are poorly determined.</p>
<p>Regime 2:</p>
<p>Intercept                    0.03554    0.04778    0.744    0.459</p>
<p>AR1                            0.79349    0.06418   12.364        0</p>
<p>MA1                         -0.76904    0.51601     -1.49   0.139</p>
<p>Error Variance^(1/2)           0.01819     0.0031</p>
<p><strong>CONCLUSION</strong><br />
The analysis in Appendix II suggests that the residual process is stable and Gaussian.  In other words, the two-state Markov model is able to account for the non-Normality of the returns process and extract the salient autoregressive and moving average features in a way that makes economic sense.</p>
<p>How is this information useful?  Potentially in two ways:</p>
<p>(i)     If the market state can be forecast successfully, we can use that information to increase our capital allocation during periods when the process is predicted to be in State 1, and reduce the allocation at times when it is in State 2.</p>
<p>(ii)    By examining the timing of the Markov states and considering different features of the market during the contrasting periods, we might be able to identify additional explanatory factors that could be used to further enhance the trading model.</p>
<p><a rel="attachment wp-att-351" href="http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/forecasts/"><img class="aligncenter size-medium wp-image-351" title="Forecasts" src="http://jonathankinlay.com/wp-content/uploads/Forecasts-300x172.jpg" alt="" width="300" height="172" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/04/a-practical-application-of-regime-switching-models/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Regime-Switching &amp; Market State Modeling</title>
		<link>http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/</link>
		<comments>http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/#comments</comments>
		<pubDate>Sun, 10 Apr 2011 15:19:56 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[ARMA]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[Fat Tails]]></category>
		<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[Markov State Models]]></category>
		<category><![CDATA[Regime Shifts]]></category>
		<category><![CDATA[ARMA Models]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=294</guid>
		<description><![CDATA[The Excel workbook referred to in this post can be downloaded here. Market state models are amongst the most useful analytical techniques that can be helpful in developing alpha-signal generators.  That term covers a great deal of ground, with ideas drawn from statistics, econometrics, physics and bioinformatics.  The purpose of this short note is to...]]></description>
			<content:encoded><![CDATA[<p>The Excel workbook referred to in this post can be downloaded <a title="Regime Change Example" href="http://www.jonathankinlay.com/Articles/RegimeChangeExample.zip">here</a>.</p>
<p>Market state models are amongst the most useful analytical techniques that can be helpful in developing alpha-signal generators.  That term covers a great deal of ground, with ideas drawn from statistics, econometrics, physics and bioinformatics.  The purpose of this short note is to provide an introduction to some of the key ideas and suggest ways in which they might usefully applied in the context of researching and developing trading systems.</p>
<p>Although they come from different origins, the concepts presented here share common foundational principles: </p>
<ol>
<li>Markets operate in different states that may be characterized by various measures (volatility, correlation, microstructure, etc);</li>
<li>Alpha signals can be generated more effectively by developing models that are adapted to take account of different market regimes;</li>
<li>Alpha signals may be combined together effectively by taking account of the various states that a market may be in.</li>
</ol>
<p>Market state models have shown great promise is a variety of applications within the field of applied econometrics in finance, not only for price and market direction forecasting, but also basis trading, index arbitrage, statistical arbitrage, portfolio construction, capital allocation and risk management.</p>
<p> <strong>REGIME SWITCHING MODELS</strong></p>
<p>These are econometric models which seek to use statistical techniques to characterize market states in terms of different estimates of the parameters of some underlying linear model.  This is accompanied by a transition matrix which estimates the probability of moving from one state to another.</p>
<p> To illustrate this approach I have constructed a simple example, given in the accompanying Excel workbook.  In this model the market operates as follows:</p>
<p> <a rel="attachment wp-att-310" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/eqn-1-6/"><img class="aligncenter size-full wp-image-310" title="Eqn 1 ARMA(1,1) Model" src="http://jonathankinlay.com/wp-content/uploads/Eqn-15.jpg" alt="" width="750" height="55" /></a><a href="http://jonathankinlay.com/?attachment_id=299"> </a>Where</p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-size: small;"><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">Y<sub>t</sub> is a variable of interest (e.g. the return in an asset over the next period t)</span><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></span></p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-size: small;"><span style="font-family: Symbol;">e</span><sub><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">t</span></sub><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;"> is an error process with constant variance </span><span style="font-family: Symbol;">s</span><sup><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">2</span></sup><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></span></p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-size: small;"><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">S is the market state, with two regimes (S=1 or S=2)</span><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></span></p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-size: small;"><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">a<sub>0</sub> is the drift in the asset process</span><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></span></p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-size: small;"><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;">a<sub>1</sub> is an autoregressive term, by which the return in the current period is dependent on the prior period return</span><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></span></p>
<p class="MsoNormal" style="line-height: 14.25pt; margin: 0in 0in 0pt 0.5in;"><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;;"><span style="font-size: small;">b<sub>1</sub> is a moving average term, which smoothes the error process</span></span><span style="font-family: &quot;Georgia&quot;,&quot;serif&quot;; font-size: 10pt;"> </span></p>
<p> This is one of the simplest possible structures, which in more general form can include multiple states, and independent regressions X<sub>i</sub> as explanatory variables (such as book pressure, order flow, etc):</p>
<p> <a href="http://jonathankinlay.com/?attachment_id=306"> </a><a rel="attachment wp-att-313" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/eqn-2-3/"><img class="aligncenter size-full wp-image-313" title="Eqn 2 General Model" src="http://jonathankinlay.com/wp-content/uploads/Eqn-22.jpg" alt="" width="750" height="111" /></a></p>
<p>The form of the error process e<sub>t </sub>may also be dependent on the market state.  It may simply be that, as in this example, the standard deviation of the error process changes from state to state.  But the changes can also be much more complex:  for instance, the error process may be non-Gaussian, or it may follow a formulation from the GARCH framework.</p>
<p>In this example the state parameters are as follows:</p>
<table border="0" cellspacing="0" cellpadding="0" width="205">
<tbody>
<tr>
<td width="77" valign="bottom"> </td>
<td width="64" valign="bottom"><strong>Reg1</strong></td>
<td width="64" valign="bottom"><strong>Reg 2</strong></td>
</tr>
<tr>
<td width="77" valign="bottom">s</td>
<td width="64" valign="bottom">0.01</td>
<td width="64" valign="bottom">0.02</td>
</tr>
<tr>
<td width="77" valign="bottom">a0</td>
<td width="64" valign="bottom">0.005</td>
<td width="64" valign="bottom">-0.015</td>
</tr>
<tr>
<td width="77" valign="bottom">a1</td>
<td width="64" valign="bottom">0.40</td>
<td width="64" valign="bottom">0.70</td>
</tr>
<tr>
<td width="77" valign="bottom">b1</td>
<td width="64" valign="bottom">0.10</td>
<td width="64" valign="bottom">0.20</td>
</tr>
</tbody>
</table>
<p> </p>
<p>What this means is that, in the first state the market tends to trend upwards with relatively low volatility.  In the second state, not only is market volatility much higher, but also the trend is 3x as large in the negative direction.</p>
<p>I have specified the following state transition matrix:</p>
<table border="0" cellspacing="0" cellpadding="0" width="205">
<tbody>
<tr>
<td width="77" valign="bottom"> </td>
<td width="64" valign="bottom">Reg1</td>
<td width="64" valign="bottom">Reg2</td>
</tr>
<tr>
<td width="77" valign="bottom">Reg1</td>
<td width="64" valign="bottom">0.85</td>
<td width="64" valign="bottom">0.15</td>
</tr>
<tr>
<td width="77" valign="bottom">Reg2</td>
<td width="64" valign="bottom">0.90</td>
<td width="64" valign="bottom">0.10</td>
</tr>
</tbody>
</table>
<p> </p>
<p>This is interpreted as follows:  if the market is in State 1, it will tend to remain in that state 85% of the time, transitioning to State 2 15% of the time.  Once in State 2, the market tends to revert to State 1 very quickly, with 90% probability.  So the system is in State 1 most of the time, trending slowly upwards with low volatility and occasionally flipping into an aggressively downward trending phase with much higher volatility.</p>
<p>The Generate sheet in the Excel workbook shows how observations are generated from this process, from which we select a single instance of 3,000 observations, shown in sheet named Sample.</p>
<p>The sample looks like this:</p>
<p><a rel="attachment wp-att-316" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-1/"></a></p>
<div id="_mcePaste" class="mcePaste" style="position: absolute; width: 1px; height: 1px; overflow: hidden; top: 0px; left: -10000px;">﻿</div>
<div><span style="font-size: small;"><span style="font-family: Calibri;"><a rel="attachment wp-att-316" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-1/"><img class="aligncenter size-medium wp-image-316" title="Chart 1" src="http://jonathankinlay.com/wp-content/uploads/Chart-1-300x180.jpg" alt="" width="300" height="180" /></a> </span></span></div>
<div><span style="font-size: small;"><span style="font-family: Calibri;"> </span></span></div>
<div><span style="font-size: small;"><span style="font-family: Calibri;"> </span></span></div>
<p><span style="font-size: small;"><span style="font-family: Calibri;"> </span></span><span style="font-size: small;"><span style="font-family: Calibri;"><span style="font-size: small;">As anticipated, the market is in State 1 most of the time, occasionally flipping into State 2 for brief periods.</span></span></span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"> </p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><a rel="attachment wp-att-317" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-2/"></a></span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><a rel="attachment wp-att-317" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-2/"><img class="aligncenter size-medium wp-image-317" title="Chart 2" src="http://jonathankinlay.com/wp-content/uploads/Chart-2-300x178.jpg" alt="" width="300" height="178" /></a> </span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"> </span><span style="font-size: small;">It is well-known that in financial markets we are typically dealing with highly non-Gaussian distributions.<span style="mso-spacerun: yes;">  </span>Non-Normality can arise for a number of reasons, including changes in regimes, as illustrated here.<span style="mso-spacerun: yes;">  </span>It is worth noting that, even though in this example the process in either market state follows a Gaussian distribution, the combined process is distinctly non-Gaussian in form, having (extremely) fat tails, as shown by the QQ-plot below.</span></p>
<p class="MsoListParagraphCxSpLast" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"> </span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"> <a rel="attachment wp-att-320" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-3/"><img class="aligncenter size-medium wp-image-320" title="Chart 3" src="http://jonathankinlay.com/wp-content/uploads/Chart-3-300x172.jpg" alt="" width="300" height="172" /></a><a rel="attachment wp-att-320" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-3/"></a></p>
<p class="MsoListParagraphCxSpFirst" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;">If we attempt to fit a standard ARMA model to the process, the outcome is very disappointing in terms of the model’s poor explanatory power (R<sup>2</sup> 0.5%) and lack of fit in the squared-residuals:</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpLast" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">ARIMA(1,0,1)</span></span></p>
<p class="MsoNormal" style="margin: 0in 0in 10pt;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">         </span>Estimate<span style="mso-spacerun: yes;">  </span>Std. Err.<span style="mso-spacerun: yes;">   </span>t Ratio<span style="mso-spacerun: yes;">  </span>p-Value</span></span></p>
<p class="MsoListParagraphCxSpFirst" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Intercept<span style="mso-spacerun: yes;">                      </span>0.00037<span style="mso-spacerun: yes;">   </span><span style="mso-spacerun: yes;"> </span>0.00032<span style="mso-spacerun: yes;">     </span>1.164<span style="mso-spacerun: yes;">    </span>0.244</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">AR1<span style="mso-spacerun: yes;">                            </span>0.57261<span style="mso-spacerun: yes;">     </span>0.1697<span style="mso-spacerun: yes;">     </span>3.374<span style="mso-spacerun: yes;">    </span>0.001</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">MA1<span style="mso-spacerun: yes;">                           </span>-0.63292<span style="mso-spacerun: yes;">    </span>0.16163<span style="mso-spacerun: yes;">    </span>-3.916<span style="mso-spacerun: yes;">        </span>0</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Error Variance^(1/2)<span style="mso-spacerun: yes;">           </span>0.02015<span style="mso-spacerun: yes;">     </span>0.0004<span style="mso-spacerun: yes;">    </span>&#8212;&#8212;<span style="mso-spacerun: yes;">   </span>&#8212;&#8212;</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                     </span><span style="mso-spacerun: yes;">  </span>Log Likelihood = 7451.96</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Schwarz Criterion = 7435.95</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">               </span>Hannan-Quinn Criterion = 7443.64</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                     </span>Akaike Criterion = 7447.96</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                       </span>Sum of Squares =<span style="mso-spacerun: yes;">  </span>1.2172</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                            </span>R-Squared =<span style="mso-spacerun: yes;">  </span>0.0054</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                        </span>R-Bar-Squared =<span style="mso-spacerun: yes;">  </span>0.0044</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                          </span>Residual SD =<span style="mso-spacerun: yes;">  </span>0.0202</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Residual Skewness = -2.1345</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Residual Kurtosis =<span style="mso-spacerun: yes;">  </span>5.7279</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                     </span>Jarque-Bera Test = 3206.15<span style="mso-spacerun: yes;">     </span>{0}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Box-Pierce (residuals):<span style="mso-spacerun: yes;">         </span>Q(48) = 59.9785 {0.115}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Box-Pierce (squared residuals): Q(50) = 78.2253 {0.007}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">              </span>Durbin Watson Statistic = 2.01392</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>KPSS test of I(0) =<span style="mso-spacerun: yes;">  </span>0.2001<span style="mso-spacerun: yes;">    </span>{&lt;1} *</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">              </span><span style="mso-spacerun: yes;">   </span>Lo&#8217;s RS test of I(0) =<span style="mso-spacerun: yes;">  </span>1.2259<span style="mso-spacerun: yes;">  </span>{&lt;0.5} *</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Nyblom-Hansen Stability Test:<span style="mso-spacerun: yes;">  </span>NH(4)<span style="mso-spacerun: yes;">  </span>=<span style="mso-spacerun: yes;">  </span>0.5275<span style="mso-spacerun: yes;">    </span>{&lt;1}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">MA form is 1 + a_1 L +&#8230;+ a_q L^q.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Covariance matrix from robust formula.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">* KPSS, RS bandwidth = 0.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 7pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Parzen HAC kernel with Newey-West plug-in bandwidth.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;">However, if we keep the same simple form of ARMA(1,1) model, but allow for the possibility of a two-state Markov process, the picture alters dramatically:<span style="mso-spacerun: yes;">  </span>now the model is able to account for 98% of the variation in the process, as shown below.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;">Notice that we have succeeded in estimating the correct underlying transition probabilities, and how the ARMA model parameters change from regime to regime much as they should (small positive drift in one regime, large negative drift in the second, etc).</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Markov Transition Probabilities</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>P(.|1)<span style="mso-spacerun: yes;">       </span>P(.|2)</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">P(1|.)<span style="mso-spacerun: yes;">            </span>0.080265<span style="mso-spacerun: yes;">      </span>0.14613</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">P(2|.)<span style="mso-spacerun: yes;">             </span>0.91973<span style="mso-spacerun: yes;">      </span>0.85387</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"> </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                              </span>Estimate<span style="mso-spacerun: yes;">  </span>Std. Err.<span style="mso-spacerun: yes;">   </span>t Ratio<span style="mso-spacerun: yes;">  </span>p-Value</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Logistic, t(1,1)<span style="mso-spacerun: yes;">              </span>-2.43875<span style="mso-spacerun: yes;">   </span><span style="mso-spacerun: yes;">  </span>0.1821<span style="mso-spacerun: yes;">    </span>&#8212;&#8212;<span style="mso-spacerun: yes;">   </span>&#8212;&#8212;</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Logistic, t(1,2)<span style="mso-spacerun: yes;">              </span>-1.76531<span style="mso-spacerun: yes;">     </span>0.0558<span style="mso-spacerun: yes;">    </span>&#8212;&#8212;<span style="mso-spacerun: yes;">   </span>&#8212;&#8212;</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Non-switching parameters shown as Regime 1.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"> </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Regime 1: </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Intercept<span style="mso-spacerun: yes;">                     </span>-0.05615<span style="mso-spacerun: yes;">    </span>0.00315<span style="mso-spacerun: yes;">   </span>-17.826<span style="mso-spacerun: yes;">        </span>0</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">AR1<span style="mso-spacerun: yes;">                            </span>0.70864<span style="mso-spacerun: yes;">    </span>0.16008<span style="mso-spacerun: yes;">     </span>4.427<span style="mso-spacerun: yes;">        </span>0</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">MA1<span style="mso-spacerun: yes;">                           </span>-0.67382<span style="mso-spacerun: yes;">    </span>0.16787<span style="mso-spacerun: yes;">    </span>-4.014<span style="mso-spacerun: yes;">        </span>0</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Error Variance^(1/2)<span style="mso-spacerun: yes;">           </span>0.00244<span style="mso-spacerun: yes;">     </span>0.0001<span style="mso-spacerun: yes;">    </span>&#8212;&#8212;<span style="mso-spacerun: yes;">   </span>&#8212;&#8212;</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"> </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Regime 2: </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Intercept<span style="mso-spacerun: yes;">                      </span>0.00838<span style="mso-spacerun: yes;">     </span>2e-005<span style="mso-spacerun: yes;">   </span>419.246<span style="mso-spacerun: yes;">        </span>0</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">AR1<span style="mso-spacerun: yes;">                            </span>0.26716<span style="mso-spacerun: yes;">    </span>0.08347<span style="mso-spacerun: yes;">     </span>3.201<span style="mso-spacerun: yes;">    </span>0.001</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">MA1<span style="mso-spacerun: yes;">                           </span>-0.26592<span style="mso-spacerun: yes;">    </span>0.08339<span style="mso-spacerun: yes;">    </span>-3.189<span style="mso-spacerun: yes;">    </span>0.001</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"> </span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                       </span>Log Likelihood = 12593.3</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Schwarz Criterion = 12557.2</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">               </span>Hannan-Quinn Criterion = 12574.5</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                     </span>Akaike Criterion = 12584.3</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                       </span>Sum of Squares =<span style="mso-spacerun: yes;">  </span>0.0178</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                            </span>R-Squared =<span style="mso-spacerun: yes;">  </span>0.9854</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                        </span>R-Bar-Squared =<span style="mso-spacerun: yes;">  </span>0.9854</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">               </span><span style="mso-spacerun: yes;">           </span>Residual SD =<span style="mso-spacerun: yes;">  </span>0.002</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Residual Skewness = -0.0483</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>Residual Kurtosis = 13.8765</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                     </span>Jarque-Bera Test = 14778.5<span style="mso-spacerun: yes;">     </span>{0}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Box-Pierce (residuals):<span style="mso-spacerun: yes;">         </span>Q(48) = 379.511<span style="mso-spacerun: yes;">     </span>{0}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Box-Pierce (squared residuals): Q(50) = 36.8248 {0.917}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">              </span>Durbin Watson Statistic = 1.50589</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                    </span>KPSS test of I(0) =<span style="mso-spacerun: yes;">  </span>0.2332<span style="mso-spacerun: yes;">    </span>{&lt;1} *</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><span style="mso-spacerun: yes;">                 </span>Lo&#8217;s RS test of I(0) =<span style="mso-spacerun: yes;">  </span>2.1352 {&lt;0.005} *</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Nyblom-Hansen Stability Test:<span style="mso-spacerun: yes;">  </span>NH(9)<span style="mso-spacerun: yes;">  </span>=<span style="mso-spacerun: yes;">  </span>0.8396<span style="mso-spacerun: yes;">    </span>{&lt;1}</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">MA form is 1 + a_1 L +&#8230;+ a_q L^q.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Covariance matrix from robust formula.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">* KPSS, RS bandwidth = 0.</span></span></p>
<p class="MsoListParagraphCxSpLast" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;">Parzen HAC kernel with Newey-West plug-in bandwidth.</span></span></p>
<p class="MsoListParagraphCxSpLast" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="line-height: 115%; font-size: 8pt; mso-bidi-font-size: 11.0pt;"><span style="font-family: Calibri;"><a rel="attachment wp-att-321" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-4/"><img class="aligncenter size-medium wp-image-321" title="Chart 4" src="http://jonathankinlay.com/wp-content/uploads/Chart-4-300x172.jpg" alt="" width="422" height="257" /></a></span></span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><a rel="attachment wp-att-321" href="http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/chart-4/"></a></p>
<p class="MsoListParagraphCxSpFirst" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;">There are a variety of types of regime switching mechanisms we can use in state models:</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;"><strong style="mso-bidi-font-weight: normal;">Hamiltonian</strong> – the simplest, where the process mean and variance vary from state to state</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;"><strong style="mso-bidi-font-weight: normal;">Markovian</strong> – the approach used here, with state transition matrix</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;"><strong style="mso-bidi-font-weight: normal;">Explained Switching</strong> – where the process changes state as a result of the influence of some underlying variable (such as interest rate volatility, for example)</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;"><strong style="mso-bidi-font-weight: normal;">Smooth Transition</strong> – comparable to explained Markov switching, but without and explicitly probabilistic interpretation.</span></span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpMiddle" style="margin: 0in 0in 0pt 0.25in; mso-add-space: auto;"><span style="font-family: Calibri; font-size: small;"> </span></p>
<p class="MsoListParagraphCxSpLast" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"><span style="font-size: small;"><span style="font-family: Calibri;">This example is both rather simplistic and pathological at the same time:<span style="mso-spacerun: yes;">  </span>the states are well-separated , by design, whereas for real processes they tend to be much harder to distinguish.<span style="mso-spacerun: yes;">  </span>A difficulty of this methodology is that the models can be very difficult to estimate.<span style="mso-spacerun: yes;">  </span>The likelihood function tends to be very flat and there are a great many local maxima that give similar fit, but with widely varying model forms and parameter estimates.<span style="mso-spacerun: yes;">  </span>That said, this is a very rich class of models with a great many potential applications.</span></span></p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"> </p>
<p class="MsoListParagraph" style="margin: 0in 0in 10pt 0.25in; mso-add-space: auto;"> </p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/04/regime-switching-market-state-modeling/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Volatility Forecasting in Emerging Markets</title>
		<link>http://jonathankinlay.com/index.php/2011/03/forecasting-volatility-in-emerging-markets/</link>
		<comments>http://jonathankinlay.com/index.php/2011/03/forecasting-volatility-in-emerging-markets/#comments</comments>
		<pubDate>Mon, 28 Mar 2011 00:40:32 +0000</pubDate>
		<dc:creator>Jonathan</dc:creator>
				<category><![CDATA[Asian markets]]></category>
		<category><![CDATA[Cointegration]]></category>
		<category><![CDATA[Econometrics]]></category>
		<category><![CDATA[Emerging Markets]]></category>
		<category><![CDATA[FIGARCH]]></category>
		<category><![CDATA[Forecasting]]></category>
		<category><![CDATA[Fractional Cointegration]]></category>
		<category><![CDATA[Fractional Integration]]></category>
		<category><![CDATA[Granger Causality]]></category>
		<category><![CDATA[Hurst Exponent]]></category>
		<category><![CDATA[Long Memory]]></category>
		<category><![CDATA[REGARCH]]></category>
		<category><![CDATA[ARFIMA]]></category>
		<category><![CDATA[KOSPI]]></category>
		<category><![CDATA[MultiFactor Models]]></category>
		<category><![CDATA[Regime Shifts]]></category>
		<category><![CDATA[Volatility]]></category>

		<guid isPermaLink="false">http://jonathankinlay.com/?p=277</guid>
		<description><![CDATA[The great majority of empirical studies have focused on asset markets in the US and other developed economies.   The purpose of this research is to determine to what extent the findings of other researchers in relation to the characteristics of asset volatility in developed economies applies also to emerging markets.  The important characteristics observed in...]]></description>
			<content:encoded><![CDATA[<p>The great majority of empirical studies have focused on asset markets in the US and other developed economies.   The purpose of this research is to determine to what extent the findings of other researchers in relation to the characteristics of asset volatility in developed economies applies also to emerging markets.  The important characteristics observed in asset volatility that we wish to identify and examine in emerging markets include clustering, (the tendency for periodic regimes of high or low volatility) long memory, asymmetry, and correlation with the underlying returns process.  The extent to which such behaviors are present in emerging markets will serve to confirm or refute the conjecture that they are universal and not just the product of some factors specific to the intensely scrutinized, and widely traded developed markets.</p>
<p>The ten emerging markets we consider comprise equity markets in Australia, Hong Kong, Indonesia, Malaysia, New Zealand, Philippines, Singapore, South Korea, Sri Lanka and Taiwan focusing on the major market indices for those markets.   After analyzing the characteristics of index volatility for these indices, the research goes on to develop single- and two-factor REGARCH models in the form by Alizadeh, Brandt and Diebold (2002).</p>
<p><a rel="attachment wp-att-281" href="http://jonathankinlay.com/index.php/2011/03/forecasting-volatility-in-emerging-markets/cluster-analysis-of-index-volatility-processes-2/"><img class="aligncenter size-medium wp-image-281" title="Cluster Analysis of Index Volatility Processes" src="http://jonathankinlay.com/wp-content/uploads/Cluster-Analysis-of-Index-Volatility-Processes1-300x212.jpg" alt="" width="300" height="212" /></a></p>
<p style="text-align: center;">Cluster Analysis of Volatility<br />
Processes for Ten Emerging Market Indices</p>
<p style="text-align: left;">The research confirms the presence of a number of typical characteristics of volatility processes for emerging markets that have previously been identified in empirical research conducted in developed markets.  These characteristics include volatility clustering, long memory, and asymmetry.   There appears to be strong evidence of a region-wide regime shift in volatility processes during the Asian crises in 1997, and a less prevalent regime shift in September 2001. We find evidence from multivariate analysis that the sample separates into two distinct groups:  a lower volatility group comprising the Australian and New Zealand indices and a higher volatility group comprising the majority of the other indices.</p>
<p>Models developed within the single- and two-factor REGARCH framework of Alizadeh, Brandt and Diebold (2002) provide a good fit for many of the volatility series and in many cases have performance characteristics that compare favorably with other classes of models with high R-squares, low MAPE and direction prediction accuracy of 70% or more.   On the debit side, many of the models demonstrate considerable variation in explanatory power over time, often associated with regime shifts or major market events, and this is typically accompanied by some model parameter drift and/or instability.</p>
<p>Single equation ARFIMA-GARCH models appear to be a robust and reliable framework for modeling asset volatility processes, as they are capable of capturing both the short- and long-memory effects in the volatility processes, as well as GARCH effects in the kurtosis process.   The available procedures for estimating the degree of fractional integration in the volatility processes produce estimates that appear to vary widely for processes which include both short- and long- memory effects, but the overall conclusion is that long memory effects are at least as important as they are for volatility processes in developed markets.  Simple extensions to the single-equation models, which include regressor lags of related volatility series, add significant explanatory power to the models and suggest the existence of Granger-causality relationships between processes.</p>
<p>Extending the modeling procedures into the realm of models which incorporate systems of equations provides evidence of two-way Granger causality between certain of the volatility processes and suggests that are fractionally cointegrated, a finding shared with parallel studies of volatility processes in developed markets.</p>
<p>Download paper <a title="Forecasting Volatility in Emerging Markets" href="http://www.jonathankinlay.com/Articles/Volatility%20Forecasting%20in%20Emerging%20Markets.pdf" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://jonathankinlay.com/index.php/2011/03/forecasting-volatility-in-emerging-markets/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

