Good day to all! Some advice for a beginner. There is a 2MA EA, how and where to redirect it to trade on custom indicator BWAosig. I am very interested in the clear example. The EA and the indicator are enclosed. Many thanks in advance.
Hi! Would you be able to write an EA based on the indicator attached below. The indicator is based on a price channel, often overdraws true, but the gist could be interesting. The Expert Advisor should make a trade when a buy or sell arrow appears, and exit this trade when it appears in the opposite direction. I would be very grateful if anyone would respond!
set here, and justify that it will not work )
sanyooooook,
Please advise where to put the account number to make this EA work on this account only.
Here is an example:
int start()
{
// if(AccountNumber()!=123) return(0);
Somebody tell me what to do to change the volume of the lot in the advisor because it always buys at 0.1
//xxxxxxxxxxxxxxxxxxxxxxxxx
double lot(int R) { double minlot = MarketInfo(Symbol(), MODE_MINLOT);
int o = MathAbs(MathLog(minlot) *0.4343) + 0.5;
double lot = minlot;
//ooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
lot = NormalizeDouble(AccountFreeMargin() * 0.00001*R, o);//---
if (AccountFreeMargin() < lot * MarketInfo(Symbol(), MODE_MARGINREQUIRED)) {
lot = NormalizeDouble(AccountFreeMargin() / MarketInfo(Symbol(), MODE_MARGINREQUIRED), o);
}
//ooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
if(lot < minlot) lot = minlot;
double maxlot =MarketInfo(Symbol(), MODE_MAXLOT);
if(lot > maxlot) lot = maxlot;
return(lot); }
//xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Somebody tell me what to do to change the volume of the lot in the advisor because it always buys at 0.1
//xxxxxxxxxxx
double lot(int R) { double minlot = MarketInfo(Symbol(), MODE_MINLOT);
int o = MathAbs(MathLog(minlot) *0.4343) + 0.5;
double lot = minlot;
//ooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
lot = NormalizeDouble(AccountFreeMargin() * 0.00001*R, o);//---
if (AccountFreeMargin() < lot * MarketInfo(Symbol(), MODE_MARGINREQUIRED)) {
lot = NormalizeDouble(AccountFreeMargin() / MarketInfo(Symbol(), MODE_MARGINREQUIRED), o);
}
//ooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
if(lot < minlot) lot = minlot;
double maxlot =MarketInfo(Symbol(), MODE_MAXLOT);
if(lot > maxlot) lot = maxlot;
return(lot); }
//xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
//xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
extern double lot = 0.5
//xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
right? there's nothing else