View Single Post
  #5 (permalink)  
Old 11-26-2008, 09:44 AM
hayseed hayseed is offline
Junior Member
 
Join Date: Nov 2006
Posts: 18
hayseed is on a distinguished road
breakeven

hey celtiheart...... below is your ea with breakeven......

you'll notice the new inputs,
//-------
Code:
extern int    breakeven               =     30;   
extern int    addbreak                 =      0;
extern int    MagicNumber           = 120000;
extern int    fastperiods              =      3;
extern int    slowperiods             =    100;
//------

you mentioned 30 so the adjustable breakeven threshold by default is 30.....

the addbreak variable, default 0, is for instances when you might want to protect a small amount rather than a flat breakeven..... as example, a setting of 20 would roughly protect 20 pips of profit..... again, roughly.....

the fastperiods , default 3, and slowperiods, default 100, inputs allow you to vary your ma periods....

the magicnumber has been changed to 120000..... this is to avoid conflicts with all orders not placed your ea.....h
Attached Files
File Type: mq4 MARibbon w breakeven.mq4 (11.3 KB, 50 views)
Reply With Quote