PureBytes Links
Trading Reference Links
|
Terry thanks for your help.
Im having a problem making your code work because I
set my position size to 5% in each trade, wheras your
code seems to make this hard to do.
MaxTrade = 5;
marg_val = ParamToggle("Margin","50,100",1);
PS = Min(MaxTrade, percent);
PositionSize = - PS * (100/marg_val);
This code evaluates to so that 100% of my capital is
in each trade. Looking forward to any help you can
provide.
Thanks,
Erci
--- Terry <MagicTH@xxxxxxxxxxx> wrote:
> I have found, and maybe there is a better or more
> correct method, that
> to change margin to 50% in code you must DOUBLE your
> PositionSize to get
> the same answers you get when you don't have code
> and just set 50 in AA
> Margin Settings.
>
>
> So I do this:
> marg_val = paramtoggle("Margin","50,100",1);
> PositionSize = PositionSize * 100/marg_val;
>
> There are other settings I posted yesterday in a
> complete SetOptions.afl
> include file.
>
> In reality you are correct about margin. Your broker
> will not use margin
> unless/until you invest your entire account, and
> then it won't be double
> until you have invested double your entire account.
> This only makes
> sense, if you have the cash, why pay interest on
> borrowed money. Margin
> is not like futures (or Rydex) where you actually
> get 2:1 on your
> investment.
> --
> Terry
> -----Original Message-----
> From: amibroker@xxxxxxxxxxxxxxx
> [mailto:amibroker@xxxxxxxxxxxxxxx] On
> Behalf Of eric paradis
> Sent: Saturday, October 29, 2005 09:53
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: [amibroker] margin account and position
> sizing
>
>
> I have a question about what exactly happens to a
> system using margin. I have my margin set to 50%.
> The
> positionsize is -5. Both trades in the 100 and 50
> margin settings set the position to 5% of equity.
>
> My question then is this- Does the benefit of 50%
> margin only come in handy once ive used up all my
> available positions from the original 100% margin
> amount?
>
> Thanks,
>
> Eric
>
>
>
>
> __________________________________
> Yahoo! FareChase: Search multiple travel sites in
> one click.
> http://farechase.yahoo.com
>
>
>
> 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
>
>
>
>
>
>
>
__________________________________
Start your day with Yahoo! - Make it your home page!
http://www.yahoo.com/r/hs
------------------------ Yahoo! Groups Sponsor --------------------~-->
Try Online Currency Trading with GFT. Free 50K Demo. Trade
24 Hours. Commission-Free.
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/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/
|