Breakeven line indicator

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Breakeven line indicator

Postby 7510109079 » Wed Feb 13, 2019 11:35 am

Please could the attached indicator be modified so that each line has its own style (colour, line style, thickness)

BreakEven Line.lua
(6 KiB) Downloaded 358 times



Original post
viewtopic.php?f=28&t=61403&p=122644&hilit=breakeven#p122644

many thx
7510109079
FXCodeBase: Graduate
 
Posts: 410
Joined: Wed May 18, 2011 7:23 am

Re: Breakeven line indicator

Postby Apprentice » Thu Feb 14, 2019 9:23 am

Your request is added to the development list under Id Number 4477
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Breakeven line indicator

Postby 7510109079 » Thu Feb 14, 2019 2:03 pm

Actually, cancel this request. The Break-even line does not always draw in the right place> I think it needs to evaluate the Gross P/L (£/$/euro-account base currency) of positions rather than the pips
7510109079
FXCodeBase: Graduate
 
Posts: 410
Joined: Wed May 18, 2011 7:23 am

Re: Breakeven line indicator

Postby 7510109079 » Fri May 03, 2019 3:47 am

Having looked at the behaviour of the indicator further, it looks like the breakeven line is calculated to always plot in between the net long/short lines. This is fine when you have short positions above longs but does not work when your longs sit above your shorts as the supposed B/E line is placed in a negative equity position rather than a B/E equity position.

Can this be corrected?? It will need some intelligent mathematical calculations to handle multiple positions with different lot sizes. It will also have to take the equity of the pair's positions into account, not just the pip values. I have attached the code of a similar MT4 indicator which may assist with the type of calculations needed.

Also the Long Positions and short positions lines are superfluous as they show the net long and net short positions respectively and there is now internal Marketscope functionality provided for showing such lines.

thx in advance
Attachments
me_Breakeven_Line v2.4.mq4
(14.33 KiB) Downloaded 326 times
7510109079
FXCodeBase: Graduate
 
Posts: 410
Joined: Wed May 18, 2011 7:23 am


Return to Indicator and Signal Requests

Who is online

Users browsing this forum: No registered users and 21 guests