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

Re: [amibroker] Re: Equity in a loop



PureBytes Links

Trading Reference Links

Perhaps i misunderstand, but this would seem to do it:


close=cover=0;


// trendfollower

Buy=

Sell=

E=Equity(1);

Plot(E,"",2,1|styleleftaxisscale);


// countertrend 

Buy=

Sell=

E=Equity(1);

Plot(E,"",2,1|styleleftaxisscale);

1|styleleftaxisscale


// breakout system

Buy=

Sell=

E=Equity(1);

Plot(E,"",2,1|styleleftaxisscale);


For tips on developing Real-Time Auto-Trading systems visit:

http://www.amibroker.org/userkb/


Friday, March 7, 2008, 5:52:27 AM, you wrote:


> Hello Herman,


> don't know if this helps.

> I like to have i.e. 3 equityplots under my price chart, every plot

> being an equity of a different trading system. Only simple systems as

> MA Cross for trendfollowing another for breakouts and another for

> countertrend system. My idea is to visualize the conditions of a

> market by looking at the equities. If Trendfollower is going down and

> countertrend going up, i may be able to see that market goes into

> consolidation or whatever. I also like to be able to combine the

> equities to see with a single look on the chart, if combination of

> trading systems brings smoother equities etc. 


> In my code i would have 

> Buy1, Sell1 for i.e. trendfollower

> Buy2, Sell2 for countertrend 

> Buy3, sell3 for breakout system


> then the code to calculate equity for every single system and then the

> plots for equity1, equity2, equity3.

> I thought, moving forward bar by bar in a loop and checking for buy1-3

> and sell1-3 signals and then adding sellprice when selling and

> subtracting buyprice when buying should give my correct close to close

> equityvalues. But i somehow don't get that in my code and cannot see

> why :(




> 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 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

>  

> Yahoo! Groups Links


> <*> To visit your group on the web, go to:

>     http://groups.yahoo.com/group/amibroker/


> <*> Your email settings:

>     Individual Email | Traditional


> <*> To change settings online go to:

>     http://groups.yahoo.com/group/amibroker/join

>     (Yahoo! ID required)


> <*> To change settings via email:

>     mailto:amibroker-digest@xxxxxxxxxxxxxxx 

>     mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx


> <*> 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/

>  

__._,_.___

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 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

__,_._,___