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

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



PureBytes Links

Trading Reference Links




HI 
b,
<FONT face=Arial color=#0000ff 
size=2> 
Yes, 
there is a fairly easy solution to the problem you raise.   I have a 
database that contains the N100 list at any point in time.   Sucn a 
database can be obtained from various sources over the Internet.   By 
"joining" this list with daily price info, it is possible to have (as extra 
data) whether or not a particular stock was a N100 constituent on a particular 
day.   Of course, you end up with about 600 stocks that have come and 
gone into/out of the N100 over (say) the last 15 years.   Also, many 
of those stocks no longer exist in the usual data sources.
<FONT face=Arial color=#0000ff 
size=2> 
Using 
tools that I know you already have, you could put a "1" or "0" in the OI 
column of your data for such stocks on each day.   You then would have 
to multiply your actual close by ten in order to accomodate both bits of 
information.   Alternatively, you could use the "getextradata" 
(syntax?) thingie that you already use for such information.
<BLOCKQUOTE 
>
  <FONT face="Times New Roman" 
  size=2>-----Original Message-----From: b519b 
  [mailto:b519b@xxxxxxxxx]Sent: Friday, October 17, 2003 2:35 
  PMTo: amibroker@xxxxxxxxxxxxxxxSubject: [amibroker] N100 
  membership Puzzle (was Walk Forward 
  Optimization)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> Send 
  BUG REPORTS to bugs@xxxxxxxxxxxxxSend SUGGESTIONS to 
  suggest@xxxxxxxxxxxxx-----------------------------------------Post 
  AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page: <A 
  href="">http://groups.yahoo.com/group/amiquote/messages/)--------------------------------------------Check 
  group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  Your use of Yahoo! Groups is subject to the <A 
  href="">Yahoo! Terms of Service. 







Yahoo! Groups Sponsor


  ADVERTISEMENT 









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 the Yahoo! Terms of Service.