PureBytes Links
Trading Reference Links
|
That worked!! Thanks alot. I've still got a lot to learn on the
backtester objects, but this is a start.
--- In amibroker@xxxxxxxxxxxxxxx, "vlanschot" <ecbu@xxx> wrote:
>
> Perhaps the following function (adjusted from TJ's original) could
> help. Put it on top of your AFL, with Stat being the array you
want
> to determine.
>
> function FindStatAtEndTrade (Stat, dt, Value)
> {
> found = -1;
> for( i = 0; i < BarCount AND found==-1; i++ )
> {
> if( dt[ i ] == Value ) found = i;
> }
>
> result = Null;
> if( found > 1 ) result = Stat[ found ];
>
> return result;
> //return IIf( found != -1, Stat[ found], Null ); // Stat at
> end /close of trade
> }
>
> So in your for (trade=bo.getFirstTrade() . . .)-loop you place:
>
> MonthAtExit= FindStatAtEndTrade( Month(), dt,
trade.ExitDateTime );
>
> etc.
>
> PS
> --- In amibroker@xxxxxxxxxxxxxxx, "rdavenportca" <davenport.r@>
> wrote:
> >
> > Thanks, that helped, but I'm not there yet. I figured out how
to
> > add columns using the user-defined metrics. But I can't figure
out
> > how to get the data I need for each symbol, which is Month() and
> Year
> > (). This object-oriented nominclature is stumping me. Any
> > suggestions would be appreciated.
> >
> >
> >
> > --- In amibroker@xxxxxxxxxxxxxxx, Keith McCombs <kmccombs@>
wrote:
> > >
> > > Search for 'backtest' under Help. Then select "How to add
user-
> > defined
> > > metrics to backtest/optimization report"
> > >
> > > rdavenportca wrote:
> > >
> > > > I am new to Amibroker and this site. I'm in the process of
> > trying to
> > > > learn the language. It's a lot harder than TradeStation!
> > > >
> > > > I would like to add two columns to the backtester output:
> > > >
> > > > (1) the month each trade was exited
> > > > (2) the year each trade was exited
> > > >
> > > > I think this should be possible, but I can't figure out
how.
> > Any help
> > > > would be greatly appreciated.
> > > >
> > > > Regards,
> > > >
> > > > Rob
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > Please note that this group is for discussion between users
> only.
> > > >
> > > > To get support from AmiBroker please send an e-mail directly
to
> > > > SUPPORT {at} amibroker.com
> > > >
> > > > For other support material please check also:
> > > > http://www.amibroker.com/support.html
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > SPONSORED LINKS
> > > > Investment management software
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Investment+management+software&w1=Investment+management+softwa
> >
>
re&w2=Real+estate+investment+software&w3=Investment+property+software
> >
>
&w4=Software+support&w5=Real+estate+investment+analysis+software&w6=I
> > nvestment+software&c=6&s=200&.sig=_XXUzbE9l5lGlZNcMu4KNQ>
> > > > Real estate investment software
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Real+estate+investment+software&w1=Investment+management+softw
> >
>
are&w2=Real+estate+investment+software&w3=Investment+property+softwar
> >
>
e&w4=Software+support&w5=Real+estate+investment+analysis+software&w6=
> > Investment+software&c=6&s=200&.sig=5_sgDczz3ArKGMtJ9tFSJA>
> > > > Investment property software
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Investment+property+software&w1=Investment+management+software
> >
>
&w2=Real+estate+investment+software&w3=Investment+property+software&w
> >
>
4=Software+support&w5=Real+estate+investment+analysis+software&w6=Inv
> > estment+software&c=6&s=200&.sig=_N6zcwefgp4eg5n6oX5WZw>
> > > >
> > > > Software support
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Software+support&w1=Investment+management+software&w2=Real+est
> >
>
ate+investment+software&w3=Investment+property+software&w4=Software+s
> >
>
upport&w5=Real+estate+investment+analysis+software&w6=Investment+soft
> > ware&c=6&s=200&.sig=MJ2jP31F3n64RDZkDadU8w>
> > > > Real estate investment analysis software
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Real+estate+investment+analysis+software&w1=Investment+managem
> >
>
ent+software&w2=Real+estate+investment+software&w3=Investment+propert
> >
>
y+software&w4=Software+support&w5=Real+estate+investment+analysis+sof
> > tware&w6=Investment+software&c=6&s=200&.sig=GmF8PlAJASx0wrSaX5-
Zlw>
> > > > Investment software
> > > > <http://groups.yahoo.com/gads?
> >
>
t=ms&k=Investment+software&w1=Investment+management+software&w2=Real+
> >
>
estate+investment+software&w3=Investment+property+software&w4=Softwar
> >
>
e+support&w5=Real+estate+investment+analysis+software&w6=Investment+s
> > oftware&c=6&s=200&.sig=aMgGsKT4w29dMAYUzQUKzg>
> > > >
> > > >
> > > >
> > > > -------------------------------------------------------------
---
> -
> > -------
> > > > YAHOO! GROUPS LINKS
> > > >
> > > > * Visit your group "amibroker
> > > > <http://groups.yahoo.com/group/amibroker>" on the web.
> > > >
> > > > * To unsubscribe from this group, send an email to:
> > > > amibroker-unsubscribe@xxxxxxxxxxxxxxx
> > > > <mailto:amibroker-unsubscribe@xxxxxxxxxxxxxxx?
> > subject=Unsubscribe>
> > > >
> > > > * Your use of Yahoo! Groups is subject to the Yahoo!
Terms
> > of
> > > > Service <http://docs.yahoo.com/info/terms/>.
> > > >
> > > >
> > > > -------------------------------------------------------------
---
> -
> > -------
> > > >
> > >
> >
>
------------------------ Yahoo! Groups Sponsor --------------------~-->
You can search right from your browser? It's easy and it's free. See how.
http://us.click.yahoo.com/_7bhrC/NGxNAA/yQLSAA/GHeqlB/TM
--------------------------------------------------------------------~->
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For other support material please check also:
http://www.amibroker.com/support.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:
http://docs.yahoo.com/info/terms/
|