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

[amibroker] Re: Darvas Box



PureBytes Links

Trading Reference Links




Chuck -
Want to add my thanks for your work and 
insight.   Speaking for myself and our local group in Houston, I like to 
add that there are believers here and strong interest here in what you're 
doing.  We've discussed the problem with <FONT face=Arial 
size=2>backtesting with dated lists giving a survivorship bias, but know 
there's no easy way to handle the changes. Your way <FONT face=Arial 
size=2>handling multiple lists on an annual basis is 
straight forward enough and should certainly be more representative 
then going back 5 years with say the RU2K or NDX100.  We also have 
additional interest in backtesting families/screens coming from 
uncorrelated sources like the IBD 100 in addition to the market composites but 
the amount and complexity of the code goes up exponentially (?) I think; 
 since one would have to track weekly changes and have the 
historical lists in their archive. Multiple watchlists for each week may work 
for a years backtest.  If not then one might have to pack around 
100+ ATComposites arrays to reflect individual 
equity membership over time (or the Osaka plugins for data file 
input/output) but that shouldn't be a burden for today's disk drives 
or systems, only to my coding ability. 
 
Best regards
Joe Landry 
     
 
----- Original Message ----- 
<BLOCKQUOTE 
>
  <DIV 
  >From: 
  Chuck Rademacher 
  
  To: <A title=amibroker@xxxxxxxxxxxxxxx 
  href="">amibroker@xxxxxxxxxxxxxxx 
  Sent: Tuesday, January 20, 2004 8:50 
  AM
  Subject: RE: [amibroker] Russell 2000 
  constituent lists
  Ken, I'm so glad that you and others are finding these 
  historical constituent lists to be of value.   To me, it makes 
  absolutely no sense to take a current list (say the N100) and test a system 
  backwards over the last few years of stock data.  First of all, unless 
  you keep the tickers in that list up to date, stocks will fall out of it every 
  day.   More importantly, such a list contains the survivors... the 
  best performers... in the past.  As a minimum, I would encourage system 
  developers to use a single historical list (2000?) and test going forward from 
  there.   At least that approximates how trading systems MAY perform 
  on the current list going forward.Ken, you asked for an example of how 
  to use these lists.  I posted this code before, but I didn't have too 
  many believers then.   It seems that interest in (what I think is) 
  more realistic backtesting is on the rise.   Here is what I 
  do:1.  Let's say we only want to trade NASDAQ 100 stocks and that 
  we want to backtest starting in 2000.2.  I would build five 
  contiguous watchlists (2000, 2001, 2002, 2003 and 2004) using the N100 
  constituent lists that I previously posted.   Actually, looking at 
  my code, they don't have to be contiguous.3.  I would build a 
  composite watchlist containing all of the tickers in the five 
  lists.4.  I would set AB to look at the composite 
  watchlist.5.  In my trading system, I would have code similar to 
  the following:<FONT face="Courier New, Courier" 
  size=2>     InList = <FONT 
  face="Courier New, Courier" color=#0000ff size=2>IIf<FONT 
  face="Courier New, Courier" size=2>(<FONT face="Courier New, Courier" 
  color=#0000ff size=2>Year() == 
  2000<FONT 
  face="Courier New, Courier" size=2>, <FONT face="Courier New, Courier" 
  color=#0000ff size=2>InWatchList<FONT face="Courier New, Courier" 
  size=2>(<FONT face="Courier New, Courier" color=#ff00ff 
  size=2>26<FONT face="Courier New, Courier" 
  size=2>),                  
  IIf<FONT 
  face="Courier New, Courier" size=2>(<FONT face="Courier New, Courier" 
  color=#0000ff size=2>Year() == 
  2001<FONT 
  face="Courier New, Courier" size=2>, <FONT face="Courier New, Courier" 
  color=#0000ff size=2>InWatchList<FONT face="Courier New, Courier" 
  size=2>(<FONT face="Courier New, Courier" color=#ff00ff 
  size=2>27<FONT face="Courier New, Courier" 
  size=2>),                  
  IIf<FONT 
  face="Courier New, Courier" size=2>(<FONT face="Courier New, Courier" 
  color=#0000ff size=2>Year() == 
  2002<FONT 
  face="Courier New, Courier" size=2>, <FONT face="Courier New, Courier" 
  color=#0000ff size=2>InWatchList<FONT face="Courier New, Courier" 
  size=2>(<FONT face="Courier New, Courier" color=#ff00ff 
  size=2>28<FONT face="Courier New, Courier" 
  size=2>),                  
  IIf<FONT 
  face="Courier New, Courier" size=2>(<FONT face="Courier New, Courier" 
  color=#0000ff size=2>Year() == 
  2003<FONT 
  face="Courier New, Courier" size=2>, <FONT face="Courier New, Courier" 
  color=#0000ff size=2>InWatchList<FONT face="Courier New, Courier" 
  size=2>(<FONT face="Courier New, Courier" color=#ff00ff 
  size=2>29<FONT face="Courier New, Courier" 
  size=2>),                  
  IIf<FONT 
  face="Courier New, Courier" size=2>(<FONT face="Courier New, Courier" 
  color=#0000ff size=2>Year() == 
  2004<FONT 
  face="Courier New, Courier" size=2>, <FONT face="Courier New, Courier" 
  color=#0000ff size=2>InWatchList<FONT face="Courier New, Courier" 
  size=2>(<FONT face="Courier New, Courier" color=#ff00ff 
  size=2>30<FONT face="Courier New, Courier" 
  size=2>),False)))));     Buy = 
  myBuyIndicator AND Inlist;     Sell = 
  mySellIndicator;6. Of course, you could take the trouble to quit 
  positions in a stock if it falls out of the watchlist even though it is still 
  trading.   These NASDAQ lists are "as at January 1", however, and 
  aren't precise enough to incorporate this additional 
  logic.Further notes:a.  I will upload the 
  N100 lists to the amibroker-ts site for those who are interested (later 
  today).b.  If you know a better way to code around this issue, by 
  all means post it.  The above works for me, but there are probably lots 
  of ways to achieve the same objective.c.  I realise that I can 
  default to 2004==false, but I prefer the above style for documentation 
  purposes.d.  Remember that the lists that I post show de-listed 
  stocks with a prefix of '~'.   While I feel that using (more) 
  accurate watchlists is essential, I feel quite strongly about including 
  de-listed stocks.   e.  I will upload some zip files 
  containing de-listed stocks and I encourage you to give it a try using 
  them.  I probably won't have time to do the uploading until next 
  week.   I may also need another site to store them as they are quite 
  large.   f.  If there is sufficient interest and people 
  are willing to incorporate more logic in their AFL, I will make semi-annual or 
  quarterly lists.  For the record, I use daily lists using my own (non-AB) 
  systems.g.  Enjoy!!At 07:32 AM 1/20/2004 
  -0500, you wrote:
  Chuck:  I add my thanks for this 
    generous sharing you are doing. Can you or 
    someone else offer me a code snippit that would illustrate how to best use 
    these SEGREGATED lists in a basic backtest?  Running such a segregated 
    list approach vs just the current list should show much improved results, am 
    I 
  correct? Ken 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 
  
  
  Yahoo! Groups Links
  
    To visit your group on the web, go to:<A 
    href="">http://groups.yahoo.com/group/amibroker/  

    To unsubscribe from this group, send an email to:<A 
    href="">amibroker-unsubscribe@xxxxxxxxxxxxxxx  

    Your use of Yahoo! Groups is subject to the <A 
    href="">Yahoo! Terms of Service. 
  


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





Yahoo! Groups Links
To visit your group on the web, go to:http://groups.yahoo.com/group/amibroker/ 
To unsubscribe from this group, send an email to:amibroker-unsubscribe@xxxxxxxxxxxxxxx 
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.