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

Re: [amibroker] Re: How to force Backtester to Calculate Position Size on Open Price?


  • To: <amibroker@xxxxxxxxxxxxxxx>
  • Subject: Re: [amibroker] Re: How to force Backtester to Calculate Position Size on Open Price?
  • From: "Anthony Faragasso" <ajf1111@xxxxxxxx>
  • Date: Wed, 21 Jan 2009 17:09:00 -0500

PureBytes Links

Trading Reference Links

Could you run a dummy backtest using the current settings and maybe post the report ?
 
 
----- Original Message -----
From: ozzyapeman
Sent: Wednesday, January 21, 2009 4:46 PM
Subject: [amibroker] Re: How to force Backtester to Calculate Position Size on Open Price?

and here are all my other options set in the AFL.

I can't see how any of them would force the backtester to use Close
prices, but maybe one option does?

SetBarsRequired( 10000, 0 );
SetOption( "AccountMargin", 100 );
SetOption( "ActivateStopsImmediately", True );
SetOption( "AllowPositionShrinking", False );
SetOption( "AllowSameBarExit", True );
SetOption( "CommissionAmount", 3.00 );
SetOption( "CommissionMode", 2 );
SetOption( "FuturesMode", 1 );
SetOption( "InitialEquity", 100000 );
SetOption( "InterestRate", 0 );
SetOption( "MaxOpenPositions", 1 );
SetOption( "MinPosValue", 0 );
SetOption( "MinShares", 1 );
SetOption( "PriceBoundChecking", True );
SetOption( "ReverseSignalForcesExit", False );
SetOption( "UsePrevBarEquityForPosSizing", False );
SetTradeDelays( 0, 0, 0, 0 );
SetPositionSize( 1, spsShares );

--- In amibroker@xxxxxxxxxps.com, "ozzyapeman" <zoopfree@xx.> wrote:
>
> Buyprices set in AFL formula are all Open:
>
> BuyPrice = Open;
> ShortPrice = Open;
> SellPrice = Open;
> CoverPrice = Open;
>
> very wierd...
>
>
> --- In amibroker@xxxxxxxxxps.com, "Anthony Faragasso" <ajf1111@> wrote:
> >
> > Is there anywhere in your code formula that you may be specifying a
> different buyprice....because I believe the formula overrides the
> settings in the preference window..
> >
> > Anthony
> >
> >
> > ----- Original Message -----
> > From: ozzyapeman
> > To: amibroker@xxxxxxxxxps.com
> > Sent: Wednesday, January 21, 2009 3:41 PM
> > Subject: [amibroker] Re: How to force Backtester to Calculate
> Position Size on Open Price?
> >
> >
> > I've always had the trade settings set to buyprice Open.
> >
> > Unfortunately, the backtester insists on using the Close, and I
can't
> > figure out why that is.
> >
> > --- In amibroker@xxxxxxxxxps.com, "gonzagags" <gonzagags@> wrote:
> > >
> > > Try in settings- trades, set in long trades buyprice in open..
> > >
> > >
> > > --- In amibroker@xxxxxxxxxps.com, "ozzyapeman" <zoopfree@> wrote:
> > > >
> > > > Hello, even though I have set Buyprice = Open; I noticed
that the
> > > > backtester report is displaying position sizes based on the
> Close of
> > > > the bar. On some trades this makes a huge difference.
> > > >
> > > > I am backtesting Forex. And I imagine that when trading on the
> Open,
> > > a
> > > > broker like IB will use the dynamic price of the Open to
> calculate
> > > the
> > > > exchange rate and position size, since the Close price is
not yet
> > > > known at the time of the trade.
> > > >
> > > > So how do I force the backtester to mimic the above, and
calculate
> > > > position sizes based on Opens? Or is this not even an option?
> > > >
> > > > I looked up Setoption in the reference guide, and don't seem
> to see
> > > an
> > > > appropriate setting to switch.
> > > >
> > > > Any input appreciated.
> > > >
> > >
> >
> >
> >
> >
> >
> >
> >
>
----------------------------------------------------------
> >
> >
> >
> > No virus found in this incoming message.
> > Checked by AVG - http://www.avg.com
> > Version: 8.0.176 / Virus Database: 270.10.10/1906 - Release Date:
> 1/21/2009 7:07 AM
> >
>



No virus found in this incoming message.
Checked by AVG - http://www.avg.com
Version: 8.0.176 / Virus Database: 270.10.10/1906 - Release Date: 1/21/2009 7:07 AM
__._,_.___

**** IMPORTANT ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

*********************
TO GET TECHNICAL SUPPORT from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
*********************

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

For other support material please check also:
http://www.amibroker.com/support.html

*********************************




Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___