Specification
FUNCTION 1 -
continuously monitor and control leverage
if trader exceeded leverage from input value than automatically close new deals that trader try to open (already placed order should be working )
For example account leverage is 1;500
but we change allowed leverage in EA to 1;10
if trader open more deals than allowed .
EA should close all new deals that exceed the ALLOWED LEVERAGE .
RESULT= CONTROLING MAX EXPOSURE
FUNCTION 2
DRAWDOWN CONTROLER
Close all deals if hits loss limit( in percentage )
and then disable trading at all (manually and automatically ),
for example if daily loss limit is set to 1% and trader hit this limit , than EA should close all open and pending deals and also close all new deals if trader try to open , till the end of trading day or next morning ( 12 o'clock night )