PureBytes Links
Trading Reference Links
|
Hi, all:
I'm embarrassed to ask this simple question, but it has so far stumped me.
It has to do with the positionsize function. Suppose I'm using the following
positionsize statement with an initial equity of $100,000:
PositionSize = -2; //invest 2% of current equity in each trade or
$2000
Now, suppose I wanted to add a term to the right side of the above
equation, such as increasing the position size by adding 5% of profits to future
purchases after making $10,000. I first define net equity, then define the % of
profits to be added:
E=Equity(1);NetE = E-100000; //net
profitE1=iif(NetE>=10000,0.05*NetE,0);
What would the new positionsize statement be? Obviously, it would not
be
PositionSize = -2 + E1;
because algebraically, the right side of the equation is -2 + 500 or 498. I
guess what I am asking is, how does Amibroker know that a negative number
actually means a percent of current equity, and how does one add to that amount
if he wants to increase his bet size?
Al Venosa<A
href="">advenosa@xxxxxxxxxxxx<FONT
color=#0000ff>
---Outgoing mail is certified Virus
Free.Checked by AVG anti-virus system (<A
href="">http://www.grisoft.com).Version: 6.0.525 /
Virus Database: 322 - Release Date: 10/9/2003
Yahoo! Groups Sponsor
ADVERTISEMENT
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 the Yahoo! Terms of Service.
|