[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] N100 membership Puzzle (was Walk Forward Optimization)



PureBytes Links

Trading Reference Links

Al,

Before you invest a lot of time on a walk forward study of trading 
the N100 stocks, you need to decide how you will determine which 
stocks were in the N100 for past years. Otherwise, you may be 
wasting your time, or worse yet, get promising results that will not 
be repeatable in the future -- because they were never possible in 
the past -- they just appeared to be possible due to the bais caused 
by using a single N100 membership list as it stands today.

Why does is the present list not good enough? Stocks that were once 
in the N100 but may not be included in today's list (likely to to 
sub standard performance recently). Also, stocks that where around 
in 1995 but were not included in the N100 because they were too 
small, may have outperformed some stocks that were in the N100 and 
thus are now included in today's list. They will appear to have been 
N100 members in 1995 but were not so. Back testing using today's 
N100 list (or S&P500 list, etc) introduces a "cystal ball" effect. 

I have often thought of doing what you are proposing but I have not 
figured out an time effective method to get the list. 

Do you have one?

I do have method but it is too time consuming. The N100 has an ETF 
(the QQQ) and the trustees of that ETF have to file papers with the 
SEC. Those papers include a list of all the stocks included in the 
ETF. So one just has to pull the QQQ filings for each year (or 
quarter, I forget which) and compile a list of changes. 
Unfortunately the list does not include their ticker symbols. So 
there would be additional paper work spent looking up tickers. Also 
on will need to get price data on stocks that have gone inactive. 

Unfortunately, the QQQ only covers the most recent 4 years of the 
N100's history, so this method will not work back to 1993. 
Alternatively an ETF like the SPY has a much longer history. 
However, its membership size of 500 would be a much large task to 
set up. 

If one had data on N100 membeship, then one could write a small 
program that would put a marker into the OI field for these stocks 
to indicate the dates it was and was not a member of the N100. A 
single AFL line of code could test for that marker and thus enable 
accurate backtesting.

Does any one have a better way to handle the challenge of handling 
past membership of indexes?

b

--- In amibroker@xxxxxxxxxxxxxxx, "advenosa@xxxx" <advenosa@xxxx> 
wrote:
> Thanks, Dimitris, for the walk-forward 
> link. I must have missed this. 
> 
> Regarding your second point, will that 
> method work in portfolio backtester
> for a basket of stocks rather than for 
> one stock? For example, suppose I
> wished to optimize my system on the 
> N100 stocks at each 2-year period
> beginning in, say, 1993. I select the 
> top 7 stocks in that period and
> optimize. I then do a walk-forward test 
> on those 7 stocks for 1995 (the
> 1-year OOS period after the first IS 
> opt period) and save the composite
> equity curve developed for trading 
> those 7 top stocks in 1995. Then, in the
> next optimization period, 1994-1995, 
> I repeated the process, this time
> getting 7 different top stocks. I 
> generate an OOS equity curve for those 7
> stocks for the period 1996. I keep 
> repeating this, saving each 1-year OOS
> composite equity, then at the end 
> concatenating all those OOS composite
> equity curves together. Can this be 
> done with the code you developed? 
> 
> TIA
> 
> Al Venosa
> 



------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/