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

Re: [amibroker] Re: Creating the equity curve for indicator signal vs. buy and hold



PureBytes Links

Trading Reference Links

I also get discrepancies compared to the figure at
http://www.amibroker.com/members/traders/11-2003.html

I am used Amibroker 4.49.0, Yahoo EOD data, and tested the BA symbol from
7/1/2001 to 9/1/2003.

    a) no evidence of the equity curve gaining during the short period from
April or so to November or so 2002.
    b) no buy/sell/short/cover arrows on the zigzag-with-price chart (they
DO show up if I add the Built-in Price indicator, however.
    c) significantly different equity and buy-and-hold values.

I am attaching chart sheet, Automatic Analysis settings file, and the
(regular) backtest report file in the hopes that will help resolve the
discrepancies.

Any chance you can rerun your Backtest with my settings and your data? (BTW,
what data source do you use?)

-john



----- Original Message ----- 
From: "jmbruegge" <jmbruegge@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Friday, November 21, 2003 12:36 PM
Subject: [amibroker] Re: Creating the equity curve for indicator signal vs.
buy and hold


> Tomasz :
>
> THANK YOU - it works and looks great. I am continually amazed by this
> program (again)!! - The only bug I can find is that when the signal
> to go short shows up, the equity curve does not add the gains from
> going short to the mountain chart like in the example ??
>
> Any thoughts ?
>
> --- In amibroker@xxxxxxxxxxxxxxx, "Tomasz Janeczko" <amibroker@xxxx>
> wrote:
> > Hello,
> >
> > It is simple:
> > - put the same formula in Automatic analysis,
> > - press BACKTEST button
> > - then press EQUITY button
> >
> > Hope this helps.
> >
> > Best regards,
> > Tomasz Janeczko
> > amibroker.com
> > ----- Original Message ----- 
> > From: "jmbruegge" <jmbruegge@xxxx>
> > To: <amibroker@xxxxxxxxxxxxxxx>
> > Sent: Friday, November 21, 2003 8:58 PM
> > Subject: [amibroker] Creating the equity curve for indicator signal
> vs. buy and hold
> >
> >
> > > In the recent S&C Traders Tip for 11/2003, there is the ZIGZAG
> TREND
> > > indicator. The screenshot shows the indicator with a second
> screen
> > > below it showing a mountain chart of the value of the stock using
> the
> > > signals that are given(going long vs. going short). I am trying
> to
> > > program for this chart. Does anyone know how to create this
> second
> > > lower screen that they call the "equity curve" ?? Here is the
> summary
> > > on the S&C Trader Tip for review:
> > >
> > >
> > > FIGURE 1.
> > >
> > > The screen shot in Figure 1 shows the daily Boeing bar chart with
> > > classic 15% Zigzag line (blue), square-shaped Zigzag Trend
> indicator
> > > (dark grey) and trend ribbon in the upper pane. The green arrows
> show
> > > long entry points and red arrows show short entry points. Lower
> pane
> > > shows equity curve (red area chart) of the simple reversal
> trading
> > > system shown in the listing 1 compared to buy-and-hold equity
> curve
> > > (blue line).
> > >
> > > All help appreciated -
> > >
> > > cheers JMB
> > >
> > >
> > >
> > >
> > >
> > > Send BUG REPORTS to bugs@xxxx
> > > Send SUGGESTIONS to suggest@xxxx
> > > -----------------------------------------
> > > 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/
> > >
> > >
> > >
>
>
>
> 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/
>
>

------------------------ 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/ 


Attachment:
zigzag_112103.PNG
Description: PNG image
Attachment:
zigzag_112103.ABS
Description: Binary data
Title: AmiBroker System Test Report




  
  
    Settings
  
     
  
    Initial Equity:
    10000
    
    Periodicity/Positions:
    Daily/Long Short
  
    Commissions:
    0.50 %
    
    Annual interest rate:
    0.00%
  
    Range:
    7/1/2001 00:00:00 - 9/1/2003
    
    Apply to:
    Current Symbol
  
    Margin requirement:
    100
    
    Futures mode:
    No
  
    Def. round lot size:
    100
    
    Def. Tick Size
    0
  
    Drawdowns based on:
    High/Low prices
    
     
     
  
    Long trades
  
    Buy price:
    Open
    
    Sell price:
    Open
  
    Buy delay:
    1
    
    Sell delay:
    1
  
    Short trades
  
    Short price:
    Close
    
    Cover price:
    Close
  
    Short delay:
    1
    
    Cover delay:
    1
  
    Stops
  
    Maximum loss:
    disabled
    
    Profit target:
    disabled
  
    Value:
    0.00
    
    Value:
    0.00
  
    Exit at stop?
    no
    
    Exit at stop?
    no
  
     
  
    Trailing stop:
    disabled
    
     
     
  
    Value:
    0.00
    
     
     
  
    Exit at stop?
    yes
    
     
     


  
  
    Overall performance summary
  
     
  
    Total net profit:
    5057.42
     
    Total commissions paid:
    393.03
  
    Return on account:
    50.57 % 
     
    Open position gain/loss
    3217.61
  
    Buy&Hold profit:
    -1985.60
     
    Bars (avg. days) in test:
    542 (789)
  
    Buy&Hold % return:
    -19.86%
     
    System to Buy&Hold index:
    354.70%
  
     
  
    Annual system % return:
    20.85%
     
    Annual B&H % return:
    -9.73%
  
     
  
    System drawdown:
    -566.00
     
    B&H drawdown:
    -3184.53
  
    Max. system drawdown:
    -2935.64
     
    B&H max. drawdown:
    -3534.53
  
    Max. system % drawdown:
    -24.77%
     
    B&H max. % drawdown:
    -33.28%
  
    Max. trade drawdown:
    -2670.96
     
     
     
  
    Max. trade % drawdown:
    -20.81%
     
     
     
  
    Trade drawdown:
    -2062.82
     
     
     
  
     
  
    Total number of trades:
    4
     
    Percent profitable:
    50.0%
  
    Number winning trades:
    2
     
    Number losing trades:
    2
  
    Profit of winners:
    3836.06
     
    Loss of losers:
    -2053.41
  
    Total # of bars in winners:
    282
     
    Total # of bars in losers:
    128
  
    Commissions paid in winners:
    151.94
     
    Commissions paid in losers:
    241.09
  
     
  
    Largest winning trade:
    2235.27
     
    Largest losing trade:
    -1867.79
  
    # of bars in largest winner:
    141
     
    # bars in largest loser:
    72
  
    Commission paid in largest winner:
    74.73
     
    Commission paid in largest loser:
    123.47
  
     
  
    Average winning trade:
    1918.03
     
    Average losing trade:
    -1026.70
  
    Avg. # of bars in winners:
    141.0
     
    Avg. # bars in losers:
    64.0
  
    Avg. commission paid in winner:
    75.97
     
    Avg. commission paid in loser:
    120.54
  
    Max consec. winners:
    2
     
    Max consec. losers:
    2
  
     
  
    Bars out of the market:
    58
     
    Interest earned:
    0.00
  
     
  
    Exposure:
    89.3%
     
    Risk adjusted ann. return:
    23.34%
  
    Ratio avg win/avg loss:
    1.87
     
    Avg. trade (win & loss):
    445.66
  
    Profit factor:
    1.87
     
    
    



  
  
    Trade list for BA 
  
    Trade
    Entry date
    Entry price
    Exit date
    Exit price
    Net Profit
    Equity value
  
    Out
    7/2/2001
    56.30
    9/28/2001
    34.41
    0.00
    10000.00
  
    Long
    9/28/2001
    34.41
    4/22/2002
    42.80
    1600.79
    11600.79
  
    Short
    4/22/2002
    43.14
    11/7/2002
    31.59
    2235.27
    13836.06
  
    Long
    11/7/2002
    33.05
    2/21/2003
    28.69
    -1867.79
    11968.27
  
    Short
    2/21/2003
    29.32
    5/12/2003
    29.49
    -185.62
    11782.65
  
    Open Long
    5/12/2003
    28.58
    8/29/2003
    36.91
    3274.77

Attachment: Description: ""

Attachment: Description: " 15057.42"