PureBytes Links
Trading Reference Links
|
Hello,
Answers below
> Like some others of you out there, I noticed that whenever I add
> position-sizing code to any of my experimental systems, the percent
> gain drops WAY down.
Percents are calculated from Initial Equity (not the part of the equity
really traded, so percents have to go down)
> ---As soon as the PositionSize variable is added to the code, the
> percentage gain results decrease dramatically. All of which leads me
> to wonder...
>
> 1) What is the default for position size used in AmiBroker's backtest
> calculations when the variable is NOT declared? Anybody know?
Default is 100% of available equity.
> --I don't think it's total equity from Settings because I tested for
> that -- when I use the PositionSize variable using "capital/close"
> (total equity as position size) the results are still way down (over
> 95% down) from teh non-declared sizing results, and if that is so,
> how can the non-declared sizings result in such better gains? It
> doesn't make sense.
You have to use negative values for PositionSize to declare percent of equity
PositionSize = -95; /* to invest 95% of equity */
> 2) Why can't these non-position sizing results be approximated using
> ANY position-sizing formula when the variable IS declared? I have
> been wracking my brain on this, to no avail.
Can be easily reproduced using this:
PositionSize = -100; /* 100% of available equity */
Final note:
PositionSize is expressed in DOLLARS not in number of shares.
Second note: please read the tutorial on backtesting.
It is clearly written there:
"Position sizing
This is a new feature in version 3.9. Position sizing in backtester is implemented by means of new reserved variable
PositionSize = <size array>
Now you can control dollar amount or percentage of portfolio that is invested into the trade
positive number define (dollar) amount that is invested into the trade for example:
PositionSize = 1000; // invest $1000 in every trade
negative numbers -100..-1 define percentage:
-100 gives 100% of current portfolio size,
-33 gives 33% of available equity for example:
"
Best regards,
Tomasz Janeczko
amibroker.com
----- Original Message -----
From: "n94612" <nkm@xxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Monday, October 21, 2002 10:42 PM
Subject: [amibroker] PositionSize Variable - Help - Inexplicable Results
>>
>
>
> 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/
>
>
>
|