Download MetaTrader 5
To add comments, please log in or register
Do you want to write a trading robot? Find solution in MQL5 Reference!
Prataprai Kaneria
290
Prataprai Kaneria 2015.10.15 22:05 

I wonder if there is an indicator for mql4 that will plot account balance and account equity in a separate window. I tried to code the indicator but

all I get  is two straight lines.

agu2a
41
agu2a 2016.11.27 03:13  
Prataprai Kaneria:

I wonder if there is an indicator for mql4 that will plot account balance and account equity in a separate window. I tried to code the indicator but

all I get  is two straight lines.

Did you find a solution?, I'm having the same issue

whroeder1
13597
whroeder1 2016.11.27 14:00  

Don't assume history is ordered by date, it's not. Could EA Really Live By Order_History Alone? (ubzen) - MQL4 forum

Once you get balances by time, you can draw your lines, from the current balance back.

As far as equity, you would have to compute the draw down per bar.
Draw down = OrderLots * (|OrderOpenPrice - OrderStopLoss at bar extreme| * DeltaPerLot) (Note OOP-OSL includes the SPREAD, and DeltaPerLot is usually around $10/pip)
Could be done, but not very easily.
/
To add comments, please log in or register