Communities

Join My Community at MyBloglog!
Blog Directory for Stittsville, Ontario
Environmental Activism Blogs - Blog Catalog Blog Directory

thenikkei225investor



Collective2 features

Entries in backtest (2)

Monday
08Dec2008

Ranking System Magic

StockMarketStudent

Sphere: Related Content                                        Stumble It!

Portfolio123 ranking system magic image
Today I am going to use some Portfolio123 ranking system magic and turn a 300% backtest into a 5000%+ backtest.  
                                                                                  

Last post I ended up with a screener backtest of short term industry strength defined by


Fmedian("RSI(7)",#Industry)>60. 

The results were as shown below holding all stocks meeting the screen criteria with weekly rebalance:

Optimized results of relative strength indicator trading system

After playing around with different ranking systems I ended up settling on one called "Fourth Generation with Unfollowed Smallcaps".  The ranking system is shown below:

Details of stock ranking system

For those people that have not been reading past posts, My universe is defined as follows:

Stock universe definition for current stock screen

The ranking system consists of fundamental and technical formulae combined with user-assigned weightings.  The system applies a ranking from 0 to 100 for each stock in the universe with 100 being the best stock choice and  0 being the worst.  Using the screen backtest I can now select how many stocks I want to hold based on the ranking system.  Below is a consolidation of the backtest results for different numbers of stocks plotted in EXCEL.

Summary of stock screen backtest using various number of stocks

This is the magic of Portfolio123 ranking systems.  300% return was turned into several thousand percent returns, not including commissions or slippage, but does include a full dose of 20-20 hindsight.  So you can't expect similar results going forward.  But it does give a nice positive bias to one's trading.  This screen may be useful for short term traders wanting to identify a small number of stocks for further analysis on a weekly basis.

The following can be found on Portfolio123:

Screen:  http://www.portfolio123.com/screen_summary.jsp?mt=1&screenid=20956

Stock Universe:  http://www.portfolio123.com/screen_summary.jsp?mt=7&screenid=20173

Ranking System:  http://www.portfolio123.com/app/ranking-system/59261

Unfortunately this doesn't help me on my quest for a long term trading system... but it was a fun exercise anyways.

Now back to the grind.

Tuesday
11Nov2008

Swimming Upstream - Backtesting the Hard Way

StockMarketStudent

Sphere: Related Content                              Stumble It!

Stock trader swimming upstream
There are always pitfalls when using bleeding edge technology.  This last week I fell into one.  Portfolio123  made some S/W enhancements while I was in the middle of some highly repetitive data capture tasks.  This caused me some grief.
   
                                                                                   
When I perform analysis on stocks I like to fix as many parameters as possible for the duration of the analysis.  Otherwise I am chasing a moving target.   When I started this exercise I chose a time period of March 1st, 2002 to October 29th, 2008.  The March 1st date was set because it was beyond the initial time period where the Portfolio123 historical database was incomplete.  Other than that it was pretty much arbitrary.  Unfortunately March 1st was not the first day of the week. My intent was to test different start dates once I had done a thorough investigation of the March 1st start date to see what the effect would be by staggering the start date.

But now Portfolio123 has thrown a wrench into my development approach.  One of the modifications that Portfolio123 did was to fix the backtester to the start of week for weekly rebalance (and other rebalance periods except for daily).  Now I can't compare future results against data I had previously gathered because I can no longer run with the same processing algorithm.  The results will be different.

So what I am going to do is publish the data I had gathered using the old Portfolio123 tool since the last post then start fresh with new baseline data.  So here we go.

I had a concern after my last post that the industry group contribution may not be all that significant compared to individual stock movement so I decided to do some tests based on stock rise instead of industry rise.  The tests were similar in nature to the industry group test looking at stock rise over varying lookback periods.   The setup screen looked as follows:

Portfolio123 Stock Screener Setup

I first ran the tests using a lookback period (n) of 60 to 300 using the rule Close(0)/Close(n) > 1.00 with weekly rebalance over the time period 03/01/02 to 10/29/08.  Then I repeated with the rule Close(0)/Close(n) < 1.00.  Below are the results graphed in EXCEL.

Portfolio stock screener backtest results

Below are the individual stock rise results and industry group rise results plotted on one graph.  I don't wish to draw any conclusions at this time since I cannot continue with the analysis.  I'll attempt to recover this train of thought once I get going with the new Portfolio123 screen backtester.

Stock rise versus industry group rise