<?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>AdaptiveTradingSystems.com Blog</title>
	<atom:link href="http://www.adaptivetradingsystems.com/blog/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.adaptivetradingsystems.com/blog</link>
	<description></description>
	<lastBuildDate>Sun, 05 Sep 2010 15:28:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Adaptive ARMD(2) SP500 Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1976</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1976#comments</comments>
		<pubDate>Sun, 29 Aug 2010 12:37:15 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Research and Development]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1976</guid>
		<description><![CDATA[Introduction This article features an adaptive autoregressive momentum &#8216;trading system&#8217; similar to the Adaptive ARM(3) Trading System. The difference between the ARM model and the ARMD model is that the momentum (delta) periods are adapted. The system trades the very short-term daily trends of the SP 500 stock market index. The two terms (weights) of [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article features an adaptive autoregressive momentum &#8216;trading system&#8217; similar to the <a href="http://www.adaptivetradingsystems.com/blog/?p=1930" target="_blank">Adaptive ARM(3) Trading System</a>. The difference between the ARM model and the ARMD model is that the momentum (delta) periods are adapted. The system trades the very short-term  daily  trends of the SP 500 stock market index. The two terms  (weights) of  the model and the delta periods are adjusted walking-forward bar by bar by the  swarm  adaptation engine.  The first delta period ranges from 1 to 3 trading days and the second ranges from 4 to 12 trading days. Both of the terms range from -0.5 to +0.5. The system is <span style="text-decoration: underline;"> highly dependent on the swarm adaptation engine</span>.</p>
<p>The model is very basic. The indicator value is calculated as follows:</p>
<p>Delta01 = (PriceSeries(t) &#8211; PriceSeries(t &#8211; Term01Period)) / (Term01Period)^0.5<br />
Delta02 = (PriceSeries(t) &#8211; PriceSeries(t &#8211; Term02Period)) / (Term02Period)^0.5</p>
<p>Indicator = Term01 * Delta01 + Term02 * Delta02</p>
<p>Term01 and Term02 are the weights of the model and TermPeriod01 and TermPeriod02 are the corresponding delta periods.</p>
<p>If the Indicator value is positive then the system goes long and vice versa. The   simplicity of the model and the uniform ranges across the terms leaves  little opportunity for curve fitting prior to the system being  run. The minimum and maximum values for the delta periods were an educated guess and are the default values for the scriptbot.</p>
<p>The   performance lookback period was set to 1,000 trading days or approximately 4 years. Once upon a time I had a strong tendency to use performance lookback periods in the range of 20 t0 100 trading days. The basic autoregressive models have been in the scriptbot library for quite a while. They would not perform well when using such short performance lookback periods.</p>
<p><strong>System Settings</strong></p>
<p>The trading system simulation was run using SP 500 stock index data   from 1980 to present. This period featured a number of very different   market regimes. The screen images that follow describe the Dakota system   settings.</p>
<div id="attachment_1997" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1997" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1997"><img class="size-medium wp-image-1997" title="Dakota Data Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-data-settings1-590x337.gif" alt="Dakota Data Settings" width="590" height="337" /></a><p class="wp-caption-text">Dakota Data Settings</p></div>
<p>The system will start to produce a trading signal around Jan 1980 (Jan 1976 + 1,000 trading days).</p>
<div id="attachment_1998" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1998" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1998"><img class="size-medium wp-image-1998" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings5-590x451.gif" alt="Dakota Bots and Swarm Settings" width="590" height="451" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>There is approximately equal opportunity for any of the whole number values that fall within the Term Period parameter ranges to be output. e.g. The Term 1 Period ranges from 0.51 to 3.49. There are three possible Term 1 Period values used by the model &#8211; 1, 2 or 3. Any values for the Term 1 Period that are greater than or equal to 0.51 and less than 1.5 will be rounded to 1. Any values for the Term 1 Period that are greater than or equal to 1.5 and less than or equal to 2.5 (&#8216;banker&#8217;s rounding&#8217;) will be rounded to 2.</p>
<div id="attachment_2001" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-2001" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=2001"><img class="size-medium wp-image-2001" title="Dakota Equity Management Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-equity-management-settings3-590x438.gif" alt="Dakota Equity Management Settings" width="590" height="438" /></a><p class="wp-caption-text">Dakota Equity Management Settings</p></div>
<p>The ATS PPIP equity engine calculates the proportion of perfect while in position. The equity engine provides the swarm adaptation engine with performance data over the performance lookback period for each trade bot in the swarm. The performance lookback period has been set to 1,000 trading days or approximately 4 years. The trading delay has been set to zero meaning that the system trades on the close of the current day session.</p>
<p><strong>Image of a Swarm in Action</strong></p>
<p>A 3 dimensional plot of each trade bots  position within the  adapted parameter space appears below. Bots that are green are  producing positive performance over the performance lookback period and  bots that are red are producing negative performance. Half of the trade  bots are ghost bots and are fixed in position. Signals generated by the  ghost bots are not used by Dakota when generating the trading signal. The bunch of green bots toward the bottom of the image belong to the  flocking swarm that produce the trading signals that are average to  produce the final trading signal on a bar by bar basis.</p>
<div id="attachment_2013" class="wp-caption alignnone" style="width: 496px"><a rel="attachment wp-att-2013" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=2013"><img class="size-full wp-image-2013" title="Dakota 3D Swarm" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-3d-swarm.gif" alt="Dakota 3D Swarm" width="486" height="441" /></a><p class="wp-caption-text">Dakota 3D Swarm</p></div>
<p><strong>Trading Simulation Results</strong></p>
<p>The Dakota Price, Signal and Equity chart appears below.</p>
<div id="attachment_2020" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-2020" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=2020"><img class="size-medium wp-image-2020" title="Dakota Price Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-and-equity-charts4-590x375.gif" alt="Dakota Price Signal and Equity Charts" width="590" height="375" /></a><p class="wp-caption-text">Dakota Price Signal and Equity Charts</p></div>
<p>The equity curve was reasonably consistent across the 30 year period from 1980 to date. Note that periods of higher volatility will result in the equity curve appearing less consistent. If a position sizing strategy was applied that reduced exposure during periods of higher volatility then the equity curve would appear much smoother than it does in this image.</p>
<p>The Dakota Trade Report follows.</p>
<div id="attachment_2022" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-2022" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=2022"><img class="size-medium wp-image-2022" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report6-590x363.gif" alt="Dakota Trades Report" width="590" height="363" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The percent of perfect is 9%. This is reasonable for a system that spans thirty years and a number of very different market regimes. The edge is a slight one, but it just might be good enough for incorporation into a system of systems built for trading a mutual fund that closely tracks the S&amp;P 500. A more complete trading simulation will be the topic of a future post.</p>
<p>A report that lists what the trading signal will be over a span of potential closing values for the S&amp;P 500 can be created by running a series of simulations. This would make trading make trading on the current close possible. I know that at least one mutual fund will take orders right up until 5 minutes before the bell rings for stocks in the S&amp;P index. There may be times when the S&amp;P 500 index moves dramatically within the last 5 minutes and the &#8216;wrong&#8217; position is taken, however, I don&#8217;t think this would be a show stopper.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1976</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>2010 End of Summer Sale!</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1972</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1972#comments</comments>
		<pubDate>Thu, 26 Aug 2010 08:57:29 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1972</guid>
		<description><![CDATA[AdaptiveTradingSystems.com is offering discounted software packages that include either a Dakota Standard EOD or Dakota Sponsor EOD license plus the complete AdaptiveTradingSystem.com package for Dakota. Here is the link -&#62; http://www.adaptivetradingsystems.com/end_of_summer_promo.html Regards, James]]></description>
			<content:encoded><![CDATA[<p>AdaptiveTradingSystems.com is offering discounted software packages that include either a Dakota Standard EOD or Dakota Sponsor EOD license plus the complete AdaptiveTradingSystem.com package for Dakota.</p>
<p>Here is the link -&gt; <a href="http://www.adaptivetradingsystems.com/end_of_summer_promo.html" target="_blank">http://www.adaptivetradingsystems.com/end_of_summer_promo.html</a></p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1972</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adaptive DV2 SP500 Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1952</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1952#comments</comments>
		<pubDate>Mon, 23 Aug 2010 04:54:54 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Research and Development]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1952</guid>
		<description><![CDATA[Introduction This article features an adaptive version of David Varadis&#8217; unbounded DV2 indicator applied to the SP 500 index on a daily time frame. Check out the DV indicators website to learn about David&#8217;s superb indicators. The DV2 indicator is calculated by dividing the close by the average of the high and the low for [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article features an adaptive version of David Varadis&#8217; unbounded DV2 indicator applied to the SP 500 index on a daily time frame. Check out the <a title="DV indicators" href="http://dvindicators.cssanalytics.com/" target="_blank">DV indicators</a> website to learn about David&#8217;s superb indicators. The DV2 indicator is calculated by dividing the close by the average of the high and the low for the day. The results for the most recent trading day and the trading day prior to that are averaged to arrive at the final DV2 indicator value.</p>
<p>The implementation of the DV2 featured here is slightly different because a DV2 period and smoothing period are configured as adapted system parameters. The DV2 period is implemented by using the highest high and lowest low over the last n trading days in the forumula. Also, there is a third adapted parameter that determines if the DV2 indicator functions as a trend following indicator or as a mean reversion indicator. Note that trading day highs and lows are very accurate for the SP 500 index, therefore it does not represent the ideal time series for application of the DV2 indicator.</p>
<p><strong>System Settings</strong></p>
<p>The trading system simulation was run using SP 500 stock index data   from 1980 to present. This period featured a number of very different   market regimes. The screen images that follow describe the Dakota system settings.</p>
<div id="attachment_1961" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1961" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1961"><img class="size-medium wp-image-1961" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings4-590x369.gif" alt="Dakota Bots and Swarm Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>The DV2 Period ranges from 0.51 to 3.49. This range was used because it assigns an approximately equal range to each of the possible 3 integer values for the DV2 Period. For example, if a given trade bot has a DV2 Period value of 0.61 then this will be rounded to 1 and 3.48 would be rounded to 3. The SMA Period is assigned the same range for the same reason. I wanted to use short term periods because the DV2 as implemented by David Varadi uses shorter term periods.</p>
<p>There is a third adapted parameter (not visible) named Counter Indicator that ranges from 0 to 1. Values less than 0.5 are rounded to zero and result in the indicator functioning in a trend following mode. Values greater than or equal to 0.5 result in the indicator functioning in a mean reversion mode. That is, when the indicator value is above upper threshold go short.</p>
<p>The Lower and Upper Thresholds are fixed at zero. The thresholds could be adapted or set to extreme values. I haven&#8217;t tried adapted thresholds for the DV2 at the time of writing this article.</p>
<p>The Equity Management settings are as per the Adaptive ARM(4) Trading System. Basically, frictionless trading with a Performance Lookback period of 1,000 trading days using the PPIP (proportion of perfect trading in position) equity engine.</p>
<p><strong>Visual Peek at a Swarm in Action</strong></p>
<p>The image below is of a 3 dimensional plot of each trade bots position within the  adapted parameter space. Bots that are green are producing positive performance over the Performance Lookback period and bots that are red are producing negative performance. Half of the trade bots are ghost bots that are fixed in position. Signals generated by the ghost bots are not used by Dakota when generating the trading signal.</p>
<div id="attachment_1962" class="wp-caption alignnone" style="width: 471px"><a rel="attachment wp-att-1962" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1962"><img class="size-full wp-image-1962" title="3D Swarm" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/3d-swarm.gif" alt="3D Swarm" width="461" height="441" /></a><p class="wp-caption-text">3D Swarm</p></div>
<p>The green bunch of trade bots that appear toward the top of the graph are the flocking bots. Signals produced by the flocking bots are used in the generation of the trading signal. All of the flocking bots have a Counter Indicator value that is above 0.5 meaning that at the bar the image was taken the DV2 indicator was functioning as a mean reversion indicator.</p>
<p><strong>Results</strong></p>
<p>The Dakota Price, Signal and Equity chart appears below.</p>
<div id="attachment_1963" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1963" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1963"><img class="size-medium wp-image-1963" title="Dakota Price Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-and-equity-charts3-590x373.gif" alt="Dakota Price Signal and Equity Charts" width="590" height="373" /></a><p class="wp-caption-text">Dakota Price Signal and Equity Charts</p></div>
<p>It is difficult to see in the above image, but the equity curve prior to the market crash in October 1987 was reasonably consistent. During the period leading up to Oct 1987 the DV2 indicator was functioning as a trend following indicator. From approximately 1992 onwards the DV2 indicator was functioning as a mean reversion indicator.</p>
<p>The Dakota Trade Report appears below.</p>
<div id="attachment_1964" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1964" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1964"><img class="size-medium wp-image-1964" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report4-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The overall trade statistics are not outstanding. This is probably due to a longish mediocre period from 1987 to approximately 2000. However, the approach looks very promising and deserves more work.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1952</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adaptive ARM(3) SP500 Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1930</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1930#comments</comments>
		<pubDate>Tue, 10 Aug 2010 03:44:11 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Research and Development]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1930</guid>
		<description><![CDATA[Introduction This article features an adaptive autoregressive momentum &#8216;trading system&#8217; similar to the Adaptive Autoregressive Trading System presented in the prior article. The system trades the very short-term daily trends of the SP 500 stock market index. The three terms (weights) of the model are modified walking-forward bar by bar by the swarm adaptation engine [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article features an adaptive autoregressive momentum &#8216;trading system&#8217; similar to the Adaptive Autoregressive Trading System presented in the prior article. The system trades the very short-term daily  trends of the SP 500 stock market index. The three terms (weights) of  the model are modified walking-forward bar by bar by the swarm  adaptation engine and they each range from -0.333 to +0.333. Thus, the  system is <span style="text-decoration: underline;">highly dependent</span> on the swarm adaptation engine.</p>
<p>The model is very basic. The predicted change in price (PD) is calculated as follows:</p>
<p>PD = Term1 * (Price(t) &#8211; Price(t-1)) + Term2 * (Price(t) &#8211; Price(t-2)) / 1.4142 + Term3 * (Price(t) &#8211; Price(t-3)) / 1.7321</p>
<p>If PD is positive then the system goes long and vice versa. The  simplicity of the model and the uniform ranges across the terms leaves little opportunity for curve fitting prior to the system being  run. The  performance lookback was set to 1,000 trading days. This model calculates all price deltas by subtracting prior closing values from the last closing value.</p>
<p><strong>System Settings</strong></p>
<p>The trading system simulation was run using SP 500 stock index data  from 1980 to present. This period featured a number of very different  market regimes. The screen images that follow describe the Dakota system  settings.</p>
<div id="attachment_1932" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1932" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1932"><img class="size-medium wp-image-1932" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings3-590x369.gif" alt="Dakota Bots and Swarm Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>The Price-ARM03 ScriptBot has been in the ATS ScriptBot Library for BioComp Dakota for some time. Default ScriptBot parameter settings were used to build the system featured in this article.</p>
<p>The Dakota Equity Management settings are identical to those described in the prior article. No slippage or commission was applied.</p>
<p><strong>Trading Simulation Results</strong></p>
<p>The screen images that follow show the results of running the trading simulation.</p>
<div id="attachment_1933" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1933" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1933"><img class="size-medium wp-image-1933" title="Dakota Price Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-and-equity-charts2-590x369.gif" alt="Dakota Price Signal and Equity Charts" width="590" height="369" /></a><p class="wp-caption-text">Dakota Price Signal and Equity Charts</p></div>
<p>Overall, the equity curve produced by the ARM(3) model is more consistent then that produced by the AR(3) model in the prior article.</p>
<div id="attachment_1936" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1936" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1936"><img class="size-medium wp-image-1936" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report3-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The hypothetical performance statistics for the ARM(3) model are slightly better than those produced by the AR(3) model.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1930</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adaptive Autoregressive SP500 Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1920</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1920#comments</comments>
		<pubDate>Sun, 08 Aug 2010 03:09:54 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Research and Development]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1920</guid>
		<description><![CDATA[Introduction This article features an adaptive &#8216;trading system&#8217; based on the good old autoregressive model. The system trades the very short-term daily trends of the SP 500 stock market index. The three terms (weights) of the model are modified walking-forward bar by bar by the swarm adaptation engine and they each range from -0.333 to [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article features an adaptive &#8216;trading system&#8217; based on the good old autoregressive model. The system trades the very short-term daily trends of the SP 500 stock market index. The three terms (weights) of the model are modified walking-forward bar by bar by the swarm adaptation engine and they each range from -0.333 to +0.333. Thus, the system is <span style="text-decoration: underline;">highly dependent</span> on the swarm adaptation engine.</p>
<p>The model is very basic. The predicted change in price (PD) is calculated as follows:</p>
<p>PD = Term1 * (Price(t) &#8211; Price(t-1)) + Term2 * (Price(t-1) &#8211; Price(t-2)) + Term3 * (Price(t-2) &#8211; Price(t-3))</p>
<p>If PD is positive then the system goes long and vice versa. The simplicity of the model and the uniform ranges across the terms means there is little opportunity for curve fitting prior to the system being run. Although, there was one optimization step taken. Initially the system was run with a performance lookback of 250 trading days. The equity curve was looking inconsistent so the run was stopped and the performance lookback was increased to 1000 trading days. No periods for the performance lookback were tested between 250 and 1000 trading days.</p>
<p><strong>System Settings</strong></p>
<p>The trading system simulation was run using SP 500 stock index data from 1980 to present. This period featured a number of very different market regimes. The screen images that follow describe the Dakota system settings.</p>
<div id="attachment_1922" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1922" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1922"><img class="size-medium wp-image-1922" title="Dakotan Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings2-590x368.gif" alt="Dakotan Bots and Swarm Settings" width="590" height="368" /></a><p class="wp-caption-text">Dakotan Bots and Swarm Settings</p></div>
<p>The Delta Period is set to 1 which means bar by bar changes in price are used. If the Delta Period was set to 2 then the first change in price would be calculated by taking the last closing value minus the closing value two trading days ago and the second change in price would be calculated by taking the closing value one trading day back minus the closing value 3 trading days back.</p>
<div id="attachment_1923" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1923" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1923"><img class="size-medium wp-image-1923" title="Dakota Equity Management Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-equity-management-settings2-590x369.gif" alt="Dakota Equity Management Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Equity Management Settings</p></div>
<p>Performance is calculated using the proportion of perfect while in position (PPIP) equity engine. The Performance Lookback period is set to 1000 trading days and the system trades on the current close of the market. A system of this nature could be used to trade the SP/ES futures because there would be time to update the data and bring the system up to date. Note, I am not suggesting that this would be appropriate for this particular system. No slippage or commission was applied.</p>
<p><strong>Trading Simulation Results</strong></p>
<p>The screen images that follow describe the results of running the trading simulation.</p>
<div id="attachment_1924" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1924" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1924"><img class="size-medium wp-image-1924" title="Dakota Price, Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-and-equity-charts1-590x369.gif" alt="Dakota Price, Signal and Equity Charts" width="590" height="369" /></a><p class="wp-caption-text">Dakota Price, Signal and Equity Charts</p></div>
<p>The equity curve shows that the system managed to adapt reasonably well over various changes in market regimes. It was interesting to see what quadrants the trade bots occupied while the system was running. Changes in market regimes were easily identified.</p>
<div id="attachment_1925" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1925" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1925"><img class="size-medium wp-image-1925" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report2-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The percent of perfect was reasonable at 8.9%. However, the system only had a slight edge on the market with approximately 50% profitable trades. Perhaps a slightly more sophisticated model, along the same lines, would result in a more substantial edge.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1920</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Countertrend / Trend Following SP Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1908</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1908#comments</comments>
		<pubDate>Thu, 05 Aug 2010 05:11:05 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Educational Articles]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1908</guid>
		<description><![CDATA[This article features a trading system for the ES/SP futures that opens trading positions counter to the short term trend when the long term trend is also counter to the short term trend. Long positions are closed when the price exceeds a shorter term simple moving average and vice versa. The trading system was built [...]]]></description>
			<content:encoded><![CDATA[<p>This article features a trading system for the ES/SP futures that opens trading positions counter to the short term trend when the long term trend is also counter to the short term trend. Long positions are closed when the price exceeds a shorter term simple moving average and vice versa.</p>
<p>The trading system was built using BioComp Dakota to enable walk-forward adaptation of the system parameter values. The system was run using daily reverse adjusted SP futures data, provided by Pinnacle Data Corp., from Jan 1994. No trading signals were generated until Jan 1995 because the performance engine requires approximately one year of data before outputting trading signals.</p>
<p>The screen images that follow show the Dakota system settings that were used.</p>
<div id="attachment_1909" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1909" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1909"><img class="size-medium wp-image-1909" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings1-590x369.gif" alt="Dakota Bots and Swarm Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>A description for each of the key trading system parameters follows:</p>
<ul>
<li>The Min Values Above/Below Last ranges from 4 to 9 trading days. For a long signal to be generated the n prior closes for the SP contract must be above the last close and vice versa. i.e. the market must be at a short term new low to go long or a short term new high to go short.</li>
<li>The MA Trend Period ranges from 100 to 300 trading days and the Trend Threshold ranges from 0% to 5%. For a long position to be generated, the last close of the SP contract is required to be above the SMA or the last close is required to be within the threshold percentage of the SMA and vice versa. i.e. If the last close is within +-x% of the SMA then both long and short positions can potentially be output.</li>
<li>The MA Exit Period ranges from 2 to 12 trading days. If the trading system is long and the last close exceeds the SMA then the position is closed and vice versa.</li>
</ul>
<div id="attachment_1912" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1912" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1912"><img class="size-medium wp-image-1912" title="Dakota Equity Management Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-equity-management-settings1-590x369.gif" alt="Dakota Equity Management Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Equity Management Settings</p></div>
<p>The Proportion of Perfect while In Position (PPIP) Equity Engine is selected and a 250 trading day Performance Lookback period has been set. The Trading Delay is set to 1 trading day. i.e. The system trades on the close of the trading day that follows the trading day that has just been processed. No commission or slippage was used. i.e. Results are frictionless.</p>
<p>The screen images that follow show the hypothetical trading results of running the system.</p>
<div id="attachment_1913" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1913" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1913"><img class="size-medium wp-image-1913" title="Dakota Price, Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-and-equity-charts-590x369.gif" alt="Dakota Price, Signal and Equity Charts" width="590" height="369" /></a><p class="wp-caption-text">Dakota Price, Signal and Equity Charts</p></div>
<p>There are some prolonged flat periods in the equity curve and the system didn&#8217;t manage to capture some of the very significant declines. These criticisms aside, overall the equity curve is quite consistent and sure beats buy and hold.</p>
<div id="attachment_1914" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1914" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1914"><img class="size-medium wp-image-1914" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report1-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The average trade period is 3.4 trading days, percent time in position is 31.4%, percent winning trades is 63% and the average winner is about equal to the average loser. If this trading signal was actually traded, versus contributing to a meta-system, then slippage and commission would have to be minimized. Given that the system signal is applied on the close of the next trading day, minimizing slippage is not difficult. Hopefully this article has given others some ideas to work with.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1908</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adaptive DVAM Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1838</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1838#comments</comments>
		<pubDate>Mon, 02 Aug 2010 02:09:28 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Research and Development]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1838</guid>
		<description><![CDATA[Introduction This article features David Varadis&#8217; DVAM indicator implemented using the BioComp Dakota application. David is a brilliant guy who generously shares some of his research on his CSS Analytics blog. If you haven&#8217;t come across the CSS Analytics blog already, then do yourself a massive favor by studying David&#8217;s articles. System Settings The Dakota [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article features David Varadis&#8217; DVAM indicator implemented using the <a title="BioComp Dakota" href="http://www.biocompsystems.com/products/Dakota/" target="_blank">BioComp Dakota</a> application. David is a brilliant guy who generously shares some of his research on his <a title="CSS Analytics" href="http://cssanalytics.wordpress.com/" target="_blank">CSS Analytics</a> blog. If you haven&#8217;t come across the CSS Analytics blog already, then do yourself a massive favor by studying David&#8217;s articles.</p>
<p><strong>System Settings</strong></p>
<p>The Dakota system settings are displayed in the following series of screen images.</p>
<div id="attachment_1839" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1839" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1839"><img class="size-medium wp-image-1839" title="Dakota Data Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-data-settings-590x368.gif" alt="Dakota Data Settings" width="590" height="368" /></a><p class="wp-caption-text">Dakota Data Settings</p></div>
<p>Reverse adjusted SP futures data, supplied by Pinnacle Data Corp.,  is loaded from 1/2/1994.</p>
<div id="attachment_1845" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1845" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1845"><img class="size-medium wp-image-1845" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-bots-and-swarm-settings-590x369.gif" alt="Dakota Bots and Swarm Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>ScriptBot DVAM-Ema-Ema is selected on the Bots and Swarm tab. This is the &#8216;raw&#8217; DVAM indicator smoothed with an EMA and then the result is smoothed again with an EMA (double EMA). The DVAM Trend Period is set to adapt between 100 and 400 trading days, the DVAM Countertrend Period adapts between 2 and 32 trading days, the period of the first EMA adapts between 2 and 24 trading days and the period of the second EMA adapts between 2 and 12 trading days. No other trading system parameters are adapted.</p>
<div id="attachment_1850" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1850" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1850"><img class="size-medium wp-image-1850" title="Dakota Equity Management Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-equity-management-settings-590x369.gif" alt="Dakota Equity Management Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Equity Management Settings</p></div>
<p>The PPIP Equity Engine is selected. Equity Engines calculate trade bot performance statistics that are used by the swarm adaptation engine to modify the adapted system parameters on a walk-forward basis. PPIP stands for proportion of perfect while in position. A Performance Lookback period of 250 trading days has been set. The Performance Lookback should probably be set to a longer period of time for this system. The Trade Delay is set to 1 trading day, which means the system trades on the close of the trading day following the day that has just been processed. No commision or slippage is applied i.e. Results are frictionless.</p>
<p><strong>Trading Simulation Results</strong></p>
<p>The screen images that follow show the results produced by the system.</p>
<div id="attachment_1853" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1853" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1853"><img class="size-medium wp-image-1853" title="Dakota Price Signal Equity and Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-price-signal-equity-charts-590x369.gif" alt="Dakota Price Signal Equity and Charts" width="590" height="369" /></a><p class="wp-caption-text">Dakota Price Signal Equity and Charts</p></div>
<p>The equity curve is reasonably smooth for a system that trades as infrequently as this one.</p>
<div id="attachment_1854" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1854" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1854"><img class="size-medium wp-image-1854" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/08/dakota-trades-report-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The Percent of Perfect is 4.7%, the average profitable trade is 97 points, the average unprofitable trade is 37 points and the average trade return is 2.8%. These statistics are quite good for a longer term trading signal. This is the type of system that I would use in conjunction with systems that trade less and more frequently when building master (meta) trading systems.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1838</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adaptive CPredictor Trading System</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1797</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1797#comments</comments>
		<pubDate>Sat, 31 Jul 2010 07:49:20 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Educational Articles]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1797</guid>
		<description><![CDATA[Introduction This article presents an example trading system constructed by running the CPredictor in BioComp Dakota. Dakota enables the creation of adaptive trading systems with 100% walk-forward out-of-sample performance evaluation. The CPredictor algorithm is basically a pattern matching algorithm. For more information on the CPredictor please read a High Level Description of the CPredictor3D Algorithm. [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>This article presents an example trading system constructed by running the CPredictor in <a title="BioComp Dakota" href="http://www.biocompsystems.com/products/Dakota/" target="_blank">BioComp Dakota</a>. Dakota  enables the creation of adaptive trading systems with 100% walk-forward out-of-sample performance evaluation. The CPredictor algorithm is basically a pattern matching algorithm. For more information on the CPredictor please read a <a title="High Level Description of the CPredictor3D Algorithm" href="http://www.adaptivetradingsystems.com/blog/?p=1777" target="_self">High Level Description of the CPredictor3D Algorithm</a>. The purpose of the CPredictor is to predict the short term trend of a given time series. An example, would be predicting the trend of an indicator such as the stochastic oscillator. The cool thing about running a CPredictor system in Dakota is that the key parameters of the CPredictor algorithm are adapted walking-forward bar by bar. The simulated trading system performance is, therefore, more likely to resemble performance after the system construction date.</p>
<p>For this example, the target series to be predicted is the short term trend of a seven  period CooksP oscillator applied to the SP reverse adjusted daily data series and smoothed with a three period EMA.  An educated guess was used to determine these parameters. No  optimization was done. Ideally, analysis would be completed to develop  or find a target series with a  short term trend that has served as an  effective target for the entire history of the traded series. An  alternative is to adapt the parameters of the target series in addition to  the parameters of the CPredictor algorithm. However, this is asking a  lot more of the swarm adaptation algorithm that is responsible for determining all adapted parameter values walking-forward bar by bar.</p>
<p><strong>Trading System Details</strong></p>
<p>The BioComp Dakota system settings are presented in a series of screen images with descriptions.</p>
<div id="attachment_1818" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1818" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1818"><img class="size-medium wp-image-1818" title="Dakota System Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/07/dakota_data_tab-590x368.gif" alt="Dakota System Settings" width="590" height="368" /></a><p class="wp-caption-text">Dakota System Settings</p></div>
<p>Reverse adjusted data for the SP contract supplied by Pinnacle Data Corp is selected as the traded series. Data from January 1st 1987 is loaded. By default, the two thousand bars prior to the bar that is being processed are required by the CPredictor to produce the trend prediction. Therefore, no trading signal will be output until January 1995. This system trades on the close of the day session. The trading signals actually apply to the trading day following that being processed. This allows for ample time to update the data and system.</p>
<div id="attachment_1823" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1823" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1823"><img class="size-medium wp-image-1823" title="Dakota Bots and Swarm Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/07/dakota_bots_swarm_tab-590x369.gif" alt="Dakota Bots and Swarm Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Bots and Swarm Settings</p></div>
<p>The CooksP-Ema-CPredictor3D scriptbot has been selected on the Dakota Bots and Swarm Settings tab. The CooksP Period is set to 7 and the EMA Period is set to 3. This defines the target series. The ranges for the three dimensions of the CPredictor3D algorithm are 1 to 10, 5 to 15 and 10 to 25 respectively. The Depth parameter is not visible in the screen image. The Depth is another adapted CPredictor parameter that can vary between 3 to 9 bars. These are the default ranges for the CPredictor3D parameters that are adapted walking-forward.</p>
<p>A total of one hundred and fifty trade bots make up the swarm. Seventy five of these trade bots are assigned to the ghost swarm. Ghost trade bots do not produce trading signals. Ghost trade bots are fixed in place within the adapted parameter / performance space and provide performance statistics for the flocking swarms that do produce trading signals. Please read the <a title="High Level Description of the ATS Swarm Adaptation Library 3.00" href="http://www.adaptivetradingsystems.com/blog/?p=1751" target="_self">High Level Description of the ATS Swarm Adaptation Library 3.00</a> for more information.</p>
<div id="attachment_1830" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1830" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1830"><img class="size-medium wp-image-1830" title="Dakota Equity Management Settings" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/07/dakota_equity_management_tab-590x369.gif" alt="Dakota Equity Management Settings" width="590" height="369" /></a><p class="wp-caption-text">Dakota Equity Management Settings</p></div>
<p>The selected Equity (performance) Engine calculates the proportion of perfect trading while in position over the Performance Lookback period of 250 trading days. &#8216;Perfect trading&#8217; is the profit that would have been made if the system had traded perfectly from close to close. The Value per Point is set to 1. This could have been set to $250 for the SP contract or $50 for the ES contract. No commissions or slippage were used. i.e. This is a frictionless trading simulation.</p>
<p>The signal that is generated today applies to the close of the market on the next trading day. The system trades both long and short and the trading signal is calculated by averaging the signals generated by the trade bots in the swarm.</p>
<p><strong>Trading Simulation Results</strong></p>
<p>The screen images that follow show the results of the trading simulation.</p>
<div id="attachment_1833" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1833" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1833"><img class="size-medium wp-image-1833" title="Dakota Price, Trading Signal and Equity Charts" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/07/dakota_charts_tab-590x369.gif" alt="Dakota Price, Trading Signal and Equity Charts" width="590" height="369" /></a><p class="wp-caption-text">Dakota Price, Trading Signal and Equity Charts</p></div>
<p>The resulting equity curve is not very smooth. However, it is definitely biased toward the upside and tends to make new highs on a regular basis. This particular CPredictor system does not represent the best that can be produced, nor is it the worst!</p>
<div id="attachment_1834" class="wp-caption alignnone" style="width: 600px"><a rel="attachment wp-att-1834" href="http://www.adaptivetradingsystems.com/blog/?attachment_id=1834"><img class="size-medium wp-image-1834" title="Dakota Trades Report" src="http://www.adaptivetradingsystems.com/blog/wp-content/uploads/2010/07/dakota_trades_report-590x369.gif" alt="Dakota Trades Report" width="590" height="369" /></a><p class="wp-caption-text">Dakota Trades Report</p></div>
<p>The system performed at 6.7% of perfect while in position. It is worth remembering that these statistics were produced by a system that&#8217;s key parameters were determined on a walk-forward basis. For a &#8216;trading system&#8217;, that trades as frequently as this one, to make the cut and be included in an ensemble of trading systems that combine to generate a production trading signal I would require approximately 8% of perfect or greater. It&#8217;s not far off the mark.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1797</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>High Level Description of the CPredictor3D Algorithm</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1777</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1777#comments</comments>
		<pubDate>Tue, 27 Jul 2010 10:35:14 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Educational Articles]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1777</guid>
		<description><![CDATA[This article describes the CPredictor3D algorithm. The CPredictor is designed to predict the short term trend of a given time series. The time series to predict can be market price data or transformed price data (oscillators etc.). The CPredictor functions best when predicting oscillating time series because the complexity of the data series is significantly [...]]]></description>
			<content:encoded><![CDATA[<p>This article describes the CPredictor3D algorithm. The CPredictor is designed to predict the short term trend of a given time series. The time series to predict can be market price data or transformed price data (oscillators etc.). The CPredictor functions best when predicting oscillating time series because the complexity of the data series is significantly less than the complexity of a &#8216;raw&#8217; market price series. The longer and sometimes very persistent trends in market price data can cause unwanted bias. It is advisable to detrend the market price data so that it is, at a minimum, weakly stationary.</p>
<p>The CPredictor is based on the k-nearest neighbor algorithm. You can think of the CPredictor as a pattern matching algorithm. The CPredictor3D is an implementation of the CPredictor that constructs the state space using three dimensions. Each of the three dimensions is calculated by subtracting the value of the given time series N periods ago from the most recent value. N will usually be a different time period for each dimension.</p>
<p>For example,</p>
<ul>
<li>Given the time series TS {-0.91,-0.80,-0.82,-0.75,-0.77,-0.54,-0.22,0.10,0.05,0.07,0.44,0.58,0.33}, where 0.33 is the most recent value and Dimension 1 (D1) period = 2, D2 Period = 5 and the D3 period = 9.</li>
<li>Value at Dimension 1 = TS(t) &#8211; TS(t-2) = 0.33 &#8211; 0.44 = -0.11</li>
<li>Value at Dimension 2 = TS(t) &#8211; TS(t-5) = 0.33 &#8211; 0.10 = 0.23</li>
<li>Value at Dimension 3 = TS(t) &#8211; TS(t-9) = 0.33 &#8211; -0.75 = 1.08</li>
</ul>
<p>Imagine the three values associated with each dimension plotted on a xyz graph. When a new value is added to the time series the values associated with each dimension are recalculated and plotted. The xyz graph is a representation of the phase space or state space. The &#8216;state&#8217; at any time period (bar number) is defined by the coordinates of the corresponding point within the state space.</p>
<p>The path through the state space is obtained by moving from point to point in the same order as the values in the time series i.e. chronological order. If you google state space or phase space you will find plenty of example diagrams. To determine when the &#8216;system&#8217; was in a similar state to any selected point, find other points that are in relatively close proximity.</p>
<p>Points that are in close proximity are called nearest neighbors. Each point in the state space maps to a time period or bar number in the time series. The last point in the path is always the point of interest because the prediction will be built from this point forward. We are not interested in points that immediately preceded the last point in a chronological sense, because these points will not be useful for the prediction.</p>
<p>For example,</p>
<ul>
<li>Three points have been identified that are in close proximity to the last point within the state space.</li>
<li>The nearest neighbors occur at (t-155), (t-329) and (t-523) i.e. 155, 329 and 523 time periods back from the last point.</li>
<li>The corresponding time periods are identified in the time series. i.e. TS(t-155), TS(t-329) and TS(t-523).</li>
</ul>
<p>The pattern matching exercise is now complete. The next step is to generate the prediction of the direction of the trend for the time series. To predict the direction of the trend from the last time period (t)  to  (t+n) calculate the equivalent deltas for each nearest neighbor in the time series and average them.</p>
<p>For example,</p>
<ul>
<li>Calculate the deltas for the nearest neighbors. Delta 1 = TS(t-153) &#8211; TS(t-155), Delta 2 = TS(t -327) &#8211; TS(t-329), Delta 3 = TS(t-521) &#8211; TS(t-523).</li>
<li>Average the deltas. Average delta = (Delta 1 + Delta 2 + Delta 3) / 3.</li>
<li>If the average delta is positive then the trend from TS(t) to TS(t+1) is predicted to be advancing and vice versa.</li>
</ul>
<p>Averaging the deltas in the time series that occur after the nearest neighbors isn&#8217;t the only approach to predicting the direction of the trend. A majority vote would be an example of another approach. Averaging the deltas is appropriate when the time series is stationary.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1777</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Static Versus Walk-Forward Curve-Fitting</title>
		<link>http://www.adaptivetradingsystems.com/blog/?p=1758</link>
		<comments>http://www.adaptivetradingsystems.com/blog/?p=1758#comments</comments>
		<pubDate>Mon, 19 Jul 2010 13:56:50 +0000</pubDate>
		<dc:creator>jamess</dc:creator>
				<category><![CDATA[Educational Articles]]></category>

		<guid isPermaLink="false">http://www.adaptivetradingsystems.com/blog/?p=1758</guid>
		<description><![CDATA[Introduction This post provides an overview of what I call &#8216;static&#8217; versus &#8216;walk-forward&#8217; curve-fitting. Trading software applications generally don&#8217;t enable walk-forward adaptation of model/indicator parameter values by default, although with some coding it often can be done. Static Curve Fitting The following points describe a problematic and often frustrating scenario. We build a trading strategy [...]]]></description>
			<content:encoded><![CDATA[<p><span><strong>Introduction</strong></span></p>
<p><span>This post provides an overview of what I call &#8216;static&#8217; versus  &#8216;walk-forward&#8217; curve-fitting. Trading software applications generally  don&#8217;t enable walk-forward adaptation of model/indicator parameter values  by default, although with some coding it often can be done.</span></p>
<p><strong>Static Curve Fitting</strong></p>
<p>The following points describe a problematic and often frustrating scenario.</p>
<ul>
<li>We build a trading strategy that makes use of a few technical  indicators (data transformations, rules etc.) to output a trading  signal.</li>
<li>We then run a curve-fitting process to determine what indicator  parameter values have been optimal for a particular market over the last  n years (modeling period).</li>
<li>We then monitor the performance of the system post construction and  we are, more than likely, disappointed to see that the performance does  not resemble the hypothetical performance over the modeling period.</li>
</ul>
<p>For this scenario, the modeling period and the trade simulation period  are one and the same. A small book could be written describing the  pitfalls of this approach. The bottom line is that hypothetical  performance over the modeling period is, in the majority of cases,  unrealistic.</p>
<p><strong>Walk-Forward Curve Fitting</strong></p>
<p>Walk-forward curve fitting can be implemented using various trading  software applications and produces more realistic hypothetical trading  results. Some trading applications require a significant amount of  programming effort to enable walk-forward adaptation because they were  not designed for this purpose. Others were designed specifically for  this purpose. The following points describe walk-forward curve fitting  at an application independent level.</p>
<ul>
<li>We use the same trading strategy as that in the static curve fitting scenario.</li>
<li>A lookback period or modeling period of 2 years is used, once again, to determine optimal indicator values.</li>
<li>A curve fitting algorithm is applied each trading day, or each X  number of trading days, over a 5 year trading simulation period using  the prior 2 years for optimization walking-forward. Assuming that our  modeling period is 504 trading days, data from t (-504) to t(-1)  is  used to determine optimal indicator parameter values, where t is the  trading day that the signal is being generated for. This is repeated for  each trading day over the 5 year period. Signals are generated for the  last 5 years, so a total of 7 years of data is required.</li>
</ul>
<p>The walk-forward curve-fitting process produces more realistic  hypothetical trading results over our trade simulation period.</p>
<p><strong>Other Things to Watch Out For<br />
</strong></p>
<p>It is  worth noting that curve/function fitting can occur at more levels than  just the determination of model/indicator values. Therefore, there is  potential for us to fool ourselves on many levels. Some examples of  curve-fitting that do not involve indicator parameter values are:</p>
<ul>
<li>Determination of the system parameter values such as the  walk-forward modeling period and the performance metrics. If the  walk-forward simulation is repeated over and over using different  modeling periods etc. until optimal system parameter values are  determined then we have curve-fit and potentially over-fit our system  over our trade simulation period. i.e We have polluted our trade  simulation period.</li>
<li> Selection of the trading strategies to apply to a given market. If  we evaluate a large set of trading strategies over our simulation  period and then select a subset to use then curve-fitting and  potentially over-fitting has occurred.</li>
<li>Selection of the data to use for the walk-forward simulation. It is  possible that the market dynamics that were dominant over the last n  years will cease to be dominant over the next year. For modeling on the  daily time frame, use 30+ years of data if that is possible.</li>
</ul>
<p>How can we avoid curve-fitting over our trade simulation period? Do  everything on a walk-forward basis or at least as much as we can, and  always be well aware of the danger.</p>
<p>Regards,</p>
<p>James</p>
]]></content:encoded>
			<wfw:commentRss>http://www.adaptivetradingsystems.com/blog/?feed=rss2&amp;p=1758</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
