Thanks for the update... mt5 did a decent job this week... If you count from 1000 more than 10%... Here is a picture... had more than 100 today... I will watch this update now, i also thought of combining mt4 with cmilliona grid6https://www.mql5.com/ru/code/12971 to see how it will work together...))
The latest version - works clearly - you can pips - when closing hands opens in the same direction, you should have some kind of delay... Started to trawl a bit more than zero... 2-4 pips, if it goes straight back... duty to think - arrows have been standing for a long time, but no position... And also, has given out more signals compared to previous ones - well, this is just a rough estimate... Well, it's still the best option ... Thanks again ... something else is silent - aou-au who else has found something ... Or do not want to jinx it ...))
Сергей Криушин: The latest version - works clearly - you can pips - when closing hands opens in the same direction, you should have some kind of delay... Started to trawl a bit more than zero... 2-4 pips, if it goes straight back... duty to think - arrows have been standing for a long time, but no position... And also, has given out more signals compared to previous ones - well, this is just a rough estimate... Well, it's still the best option ... Thanks again ... something else is silent - aou-au who else has found something ... or don't want to jinx it...))
If you have a lot of characters, it slows down until it calculates them all. The main idea is that it should not open until a new bar has appeared, that is, it should make one transaction on one bar.
Glued the signals of this strategy together with my martin advisor, this is the result from January 2015 to today
EURUSD:
USDCHF:
Mt5 also has a nice Martin fromhttps://www.mql5.com/ru/code/13315 - multiplies the last losing trade... but there are often 2 of these losing trades...
//+------------------------------------------------------------------+//| Виртуальный стоп |//+------------------------------------------------------------------+void PutLable(conststring name="",datetime time=0,double price=0,constcolor clr=clrGreen)
{
//--- сбросим значение ошибкиResetLastError();
//--- Создаем меткуif(!ObjectCreate(0,name,OBJ_ARROW_LEFT_PRICE,0,time,price))
{
Print(__FUNCTION__,
": не удалось создать левую ценовую метку! Код ошибки = ",GetLastError());
return;
//--- установим цвет меткиObjectSetInteger(0,name,OBJPROP_COLOR,clr);
//--- установим стиль окаймляющей линииObjectSetInteger(0,name,OBJPROP_STYLE,STYLE_SOLID);
//--- установим размер меткиObjectSetInteger(0,name,OBJPROP_WIDTH,2);
}
}
//+------------------------------------------------------------------+//| |//+------------------------------------------------------------------+bool isNewBar(string symbol,ENUM_TIMEFRAMES timeframe)
{
//---- получим время появления текущего бараdatetime TNew=datetime(SeriesInfoInteger(symbol,timeframe,SERIES_LASTBAR_DATE));
datetime m_TOld=0;
//--- проверка на появление нового бараif(TNew!=m_TOld && TNew)
{
m_TOld=TNew;
//--- появился новый бар!return(true);
Print("Новый бар!");
}
//--- новых баров пока нет!return(false);
}
//+------------------------------------------------------------------+//| Возвращает true, если появился новый бар для пары символ/период |//+------------------------------------------------------------------+bool IsNewBar()
{
//--- в статической переменной будем помнить время открытия последнего бараstaticdatetime last_time=0;
//--- текущее времяdatetime lastbar_time=SeriesInfoInteger(Symbol(),Period(),SERIES_LASTBAR_DATE);
//--- если это первый вызов функцииif(last_time==0)
{
//--- установим время и выйдем
last_time=lastbar_time;
return(false);
}
//--- если время отличаетсяif(last_time!=lastbar_time)
{
//--- запомним время и вернем true
last_time=lastbar_time;
return(true);
}
//--- дошли до этого места - значит бар не новый, вернем falsereturn(false);
}
//+------------------------------------------------------------------+//| Считаем лот в зависимости от полученного профита |//+------------------------------------------------------------------+doubleVolume(void)
{
double lot=Lots;
//--- Получим доступ к историиHistorySelect(0,TimeCurrent());
//--- Сделки в историиint orders=HistoryDealsTotal();
//--- Тикет последней сделки ulong ticket=HistoryDealGetTicket(orders-1);
if(ticket==0)
{
Print("Нет сделок в истории! ");
lot=Lots;
}
//--- Профит сделкиdouble profit=HistoryDealGetDouble(ticket,DEAL_PROFIT);
//--- Лот сделкиdouble lastlot=HistoryDealGetDouble(ticket,DEAL_VOLUME);
//--- Профит отрицательныйif(profit<0.0)
{
//--- Увеличиваем следующий лот
lot=lastlot*KLot;
Print(" Cделка закрыта по стопу! ");
}
//--- Приводим лот к минимальномуdouble maxvol=SymbolInfoDouble(_Symbol,SYMBOL_VOLUME_MIN);
if(lot<maxvol)
lot=maxvol;
//--- Если лот больше максимального то начальный лотif(lot>MaxLot)
lot=Lots;
//--- Возвращаем торговый объемreturn(lot);
}
//+------------------------------------------------------------------+//| Смотрим тип последней закрытой сделки |//+------------------------------------------------------------------+int LastDealType(void)
{
int type=0;
//--- Получим доступ к историиHistorySelect(0,TimeCurrent());
//--- Сделки в историиint orders=HistoryDealsTotal();
//--- Тикет последней сделки ulong ticket=HistoryDealGetTicket(orders-1);
//--- Нет сделок в историиif(ticket==0)
{
Print("Нет сделок в истории! ");
type=0;
}
if(ticket>0)
{
//--- Последняя сделка BUY if(HistoryDealGetInteger(ticket,DEAL_TYPE)==DEAL_TYPE_BUY)
{
type=2;
}
//--- Последняя сделка SELLif(HistoryDealGetInteger(ticket,DEAL_TYPE)==DEAL_TYPE_SELL)
{
type=1;
}
}
//---return(type);
}
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Fixed bugs in the MT5 version
Thanks for the update... mt5 did a decent job this week... If you count from 1000 more than 10%... Here is a picture... had more than 100 today... I will watch this update now, i also thought of combining mt4 with cmilliona grid6https://www.mql5.com/ru/code/12971 to see how it will work together...))
The latest version - works clearly - you can pips - when closing hands opens in the same direction, you should have some kind of delay... Started to trawl a bit more than zero... 2-4 pips, if it goes straight back... duty to think - arrows have been standing for a long time, but no position... And also, has given out more signals compared to previous ones - well, this is just a rough estimate... Well, it's still the best option ... Thanks again ... something else is silent - aou-au who else has found something ... or don't want to jinx it...))
Glued the signals of this strategy together with my martin advisor, this is the result from January 2015 to today
EURUSD:
USDCHF:
Glued the signals of this strategy together with my martin advisor, this is the result from January 2015 to today
EURUSD:
USDCHF:
Tried to translate for RSI indicator - didn't work... apparently it doesn't match the library...
And whereCopyBuffer lost in the trend definition block, and RSI has 70 and 30 standard levels.
Please advise where to write or who can help me to correct 2 errors in advisor '}' - unexpected end of program '{' - unbalanced parentheses TMA.mq4
Please advise where to write or who can help me to correct 2 errors in advisor '}' - unexpected end of program '{' - unbalanced parentheses TMA.mq4
Please insert code correctly:Insert code correctly on forum(I corrected your message).
Added: I also strongly recommend to use code styler - it will help to detect errors(Work with source code: Styler - Program Development).