PureBytes Links
Trading Reference Links
|
If you want only the performance of the buy and hold, it is simply the
change from the first to the last observation. Something like
100 * ( Lastvalue(C) / Ref(C,1-Cum(1)) - 1 )
will give you this performance as a percentage for the full period.
If you use
100 * ( C / Ref(C,1-Cum(1)) - 1 )
it will give you the performance of the buy and hold on that day in
stead of for the full period.
Regards
MG Ferreira
TsaTsa EOD Programmer and trading model builder
http://www.ferra4models.com
http://fun.ferra4models.com
--- In equismetastock@xxxxxxxxxxxxxxx, pumrysh <no_reply@xxxx> wrote:
> Geoff,
>
> With the limited information that you provided why not use Cum(1) to
> signify the start and finish.
>
> Buy:=Cum(1)=1;
>
> Will work for the buy. Cum(1) is the first day of data.
> If you know how many data points or days there are you could use
>
> Sell:= Cum(1)= {#of data points};
>
> You may not need this though in version 9. Check to see if you can
> exit all trades at end of test. Seems like you can.
>
> Preston
>
>
> --- In equismetastock@xxxxxxxxxxxxxxx, "Geoff" <gmb1994@xxxx> wrote:
> > How can I write the buy-and-hold formula? It would buy on the
> first
> > day and sell on the last day of the system backtest.
------------------------ Yahoo! Groups Sponsor --------------------~-->
What would our lives be like without music, dance, and theater?
Donate or volunteer in the arts today at Network for Good!
http://us.click.yahoo.com/Tcy2bD/SOnJAA/cosFAA/BefplB/TM
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|