初心者の方からの質問 MQL5 MT5 MetaTrader 5 - ページ 1328 1...132113221323132413251326132713281329133013311332133313341335...1503 新しいコメント Mikhail Tkachev 2021.07.15 12:00 #13271 地域の皆様のお力をお借りしたいのですが...。MT5複数のペアで同時にパラメータをオーバーシュートして最適化を実行できない。テスターの「シンボル」で「マーケットウォッチから全てのシンボル」を選択すると、「パラメータ」タブで入力パラメータのオーバーシュートを設定する機能が無効になり、チェックボックスがチェックされず、値が入力されないだけです。どうしたらいいのでしょうか? Mikhail Mishanin 2021.07.15 12:39 #13272 MikeZv: 地域の皆様のお力をお借りしたいのですが...。MT5複数ペアで同時にパラメータをオーバーシュートして最適化を 行うことができませんでした。テスターの「シンボル」欄で「マーケットウォッチから全てのシンボル」オプションを選択すると、「パラメータ」タブで入力パラメータのオーバーシュートを設定する機能が無効になり、ティックも値も入力されないだけになってしまいます。ど うしたらいいのでしょうか? は数文字で最適化されていない、テストしただけで Mikhail Tkachev 2021.07.15 13:06 #13273 Mikhail Mishanin:は複数文字で最適化されていません。そして、各シンボルのパラメータを個別にテストする必要があるのですか? MT4でも同様です。MT5で多通貨のテストができるのは神話なんですか? UPD しかし、ドキュメントには、明示的に: シンボルを指定しても、テスターがそのヒストリカルデータのみを使用するわけではないことを理解する必要があります。EAで使用されている全てのシンボルの情報を、テスターが自動的に読み込みます。 つまり、1つのシンボルがパラメータセットで選択され、テスターはこれらのパラメータを「EAに含まれるすべてのシンボルに」適用することになっています。 削除済み 2021.07.15 13:47 #13274 MikeZv:各シンボルのパラメータを個別にテストする必要があるのでしょうか? MT4でも同じように。MT5での多通貨テストは神話なんですか?..... テスト」と「最適化」という言葉の違いを理解していますか? Mikhail Tkachev 2021.07.15 13:56 #13275 Сергей Таболин:テスト」と「最適化」の違いを理解していますか? キャラクターごとの テストなのか、最適化なのか。 Valeriy Yastremskiy 2021.07.15 15:10 #13276 Vitaly Muzichenko:だから、彼はオープンポジションについて知っておく必要がある。 トレーディング、自動売買システム、ストラテジーテストに関するフォーラム初心者からのFAQ MQL5 MT5 MetaTrader 5アレクサンドル・エゴロフ, 2021.07.14 18:04mt5で各ペアの未決済注文の手数料を個別に計算 する方法を教えてください。 はい、私のミスです。各ペアのポジションを列挙することで、) Yuriy Vins 2021.07.15 15:45 #13277 皆さんこんにちは、MT-5ストラテジーテスターの チャート上の十字線はどこでオンになっているのか、また、全くないのか、ご存知の方はいらっしゃいますか? Vladimir Karputov 2021.07.15 15:51 #13278 Yuriy Vins: 皆さんこんにちは、MT-5ストラテジーテスターの チャート上の十字線はどこで有効になっているのか、また、そこにあるのかご存知の方はいらっしゃいますか? マウスの中ボタン(スクロールホイールをクリック) Eugen8519 2021.07.15 16:03 #13279 トレーリングストップを設定する方法を教えてくれる友達。 //+------------------------------------------------------------------+ //| EMA_WMA v2(barabashkakvn's edition).mq5 | //| Copyright © 2009, Vladimir Hlystov | //| cmillion@narod.ru | //+------------------------------------------------------------------+ #property copyright "Copyright © 2009, Vladimir Hlystov" #property link "cmillion@narod.ru" #property version "2.000" #include <Trade\PositionInfo.mqh> #include <Trade\Trade.mqh> #include <Trade\SymbolInfo.mqh> #include <Trade\AccountInfo.mqh> CPositionInfo m_position; // trade position object CTrade m_trade; // trading object CSymbolInfo m_symbol; // symbol info object CAccountInfo m_account; // account info wrapper //+------------------------------------------------------------------+ //| Enum Prices | //+------------------------------------------------------------------+ enum enPrices { pr_close, // Close pr_open, // Open pr_high, // High pr_low, // Low pr_median, // Median pr_typical, // Typical pr_weighted, // Weighted1 pr_average // Average (high+low+oprn+close)/4 }; //+------------------------------------------------------------------+ //--- Super Trend Hull Indicator int Inp_hullPeriod = 18; // Hull period int Inp_hullPeriod2 = 6660; // Hull period enPrices Inp_Price = pr_close; // Price extern double Lots = 5.0; //--- int period_EMA = 80; // EMA: averaging period int period_WMA = 80; // WMA: averaging period extern int InpStopLoss = 5000; // StopLoss extern int InpTakeProfit = 10000; // TakeProfit double my_lot; ulong m_magic=72406264; // magic number //--- double my_SL,my_TP; datetime TimeBar; double ExtStopLoss=0.0; double ExtTakeProfit=0.0; int m_bar_current=0; int handle_iCustom; // variable for storing the handle of the iCustom indicator int handle_iCustom2; // variable for storing the handle of the iCustom indicator int handle_iMA_EMA; // variable for storing the handle of the iMA indicator int handle_iMA_WMA; // variable for storing the handle of the iMA indicator int all_positions; // offene Positionen input bool Reverse = true; bool UseTimeLimit = true; int startHour = 1 ; int stopHour = 23; bool YesStop=false; input ENUM_TIMEFRAMES Timeframe = PERIOD_CURRENT; //+------------------------------------------------------------------+ //| Expert initialization function | //+------------------------------------------------------------------+ int OnInit() { //--- m_symbol.Name(Symbol()); // sets symbol name //--- m_trade.SetExpertMagicNumber(m_magic); // sets magic number if(!RefreshRates()) { Print("Error RefreshRates. Bid=",DoubleToString(m_symbol.Bid(),Digits()), ", Ask=",DoubleToString(m_symbol.Ask(),Digits())); return(INIT_FAILED); } m_symbol.Refresh(); //--- tuning for 3 or 5 digits int digits_adjust=1; if(m_symbol.Digits()==3 || m_symbol.Digits()==5) digits_adjust=10; ExtStopLoss = InpStopLoss * digits_adjust; ExtTakeProfit = InpTakeProfit * digits_adjust; //--- create handle of the indicator iMA handle_iMA_EMA=iMA(Symbol(),Period(),period_EMA,0,MODE_EMA,PRICE_OPEN); //--- if the handle is not created if(handle_iMA_EMA==INVALID_HANDLE) { //--- tell about the failure and output the error code PrintFormat("Failed to create handle of the iMA indicator for the symbol %s/%s, error code %d", Symbol(), EnumToString(Period()), GetLastError()); //--- the indicator is stopped early return(INIT_FAILED); } //--- create handle of the indicator iMA handle_iMA_WMA=iMA(Symbol(),Period(),period_WMA,0,MODE_LWMA,PRICE_OPEN); //--- if the handle is not created if(handle_iMA_WMA==INVALID_HANDLE) { //--- tell about the failure and output the error code PrintFormat("Failed to create handle of the iMA indicator for the symbol %s/%s, error code %d", Symbol(), EnumToString(Period()), GetLastError()); //--- the indicator is stopped early return(INIT_FAILED); } //--- create handle of the indicator iCustom handle_iCustom=iCustom(m_symbol.Name(),Period(),"hull_variation",Inp_hullPeriod,Inp_Price ); handle_iCustom2=iCustom(m_symbol.Name(),Period(),"23",Inp_hullPeriod2,Inp_Price ); //--- if the handle is not created if(handle_iCustom==INVALID_HANDLE || handle_iCustom2==INVALID_HANDLE) { //--- tell about the failure and output the error code PrintFormat("Failed to create handle of the iCustom indicator for the symbol %s/%s, error code %d", m_symbol.Name(), EnumToString(Period()), GetLastError()); //--- the indicator is stopped early return(INIT_FAILED); } //--- return(INIT_SUCCEEDED); } //+------------------------------------------------------------------+ //| Expert tick function | //+------------------------------------------------------------------+ int Crossed(double line1,double line2) { static int last_direction=0; static int current_direction=0; //--- don't work in the first load, wait for the first cross! static bool first_time=true; if(first_time==true) { first_time=false; //--- if(line1>line2) current_direction=1; //up else current_direction=2; //(line1<line2) //down last_direction=current_direction; //--- return (0); } //--- if(line1>line2) current_direction=1; //up else current_direction=2; //(line1<line2) //down //--- if(current_direction!=last_direction) //changed { last_direction=current_direction; return(last_direction); } else { return(0); //not changed } } void OnTick() { double close1 = iClose(_Symbol,Timeframe,1); datetime time_0=iTime(0); if(TimeBar==time_0) return; if(TimeBar==0) { TimeBar=time_0; return; }//first program run double colorBuffer[],hull[],EMA0[],WMA0[]; ArraySetAsSeries(colorBuffer,true); ArraySetAsSeries(hull,true); ArraySetAsSeries(EMA0,true); ArraySetAsSeries(WMA0,true); int start_pos=1,count=3; if(!iGetArray(handle_iCustom,1,start_pos,count,colorBuffer)) return; if(!iGetArray(handle_iCustom2,1,start_pos,count,hull)) return; if(!iGetArray(handle_iMA_EMA,0,start_pos,count,EMA0)) return; if(!iGetArray(handle_iMA_WMA,0,start_pos,count,WMA0)) return; //--- if(UseTimeLimit) { YesStop=true; MqlDateTime str1; TimeToStruct(TimeCurrent() , str1); if(str1.hour > startHour && str1.hour < stopHour) YesStop=false; } if(YesStop==false) ulong m_ticket=0; double SEma,LEma; SEma = iMAGet(handle_iMA_WMA,0); LEma = iMAGet(handle_iMA_EMA,0); static int isCrossed=0; if(!Reverse) isCrossed=Crossed(LEma,SEma); else isCrossed=Crossed(SEma,LEma); //--- if(!RefreshRates()) return; { bool Buy_Condition_1 = (WMA0[m_bar_current] < EMA0[m_bar_current+1]); bool Buy_Condition_2 = (close1 > WMA0[0]); { int pos_total=PositionsTotal(); if(pos_total==0) { if(isCrossed==1) { if(!RefreshRates()) return; TimeBar=time_0; my_TP = m_symbol.Ask() + ExtTakeProfit*Point(); my_SL = m_symbol.Ask() - ExtStopLoss*Point(); my_lot = Lots; OPENORDER("Sell"); } } if(isCrossed==2) { if(!RefreshRates()) return; TimeBar=time_0; my_TP = m_symbol.Bid() - ExtTakeProfit*Point(); my_SL = m_symbol.Bid() + ExtStopLoss*Point(); my_lot= Lots; OPENORDER("Buy"); } } } if(colorBuffer[m_bar_current+1]>colorBuffer[m_bar_current] ) //Buy { if(!RefreshRates()) return; TimeBar=time_0; CLOSEORDER("Sell"); } if(colorBuffer[m_bar_current+1]<colorBuffer[m_bar_current] ) //Sell { if(!RefreshRates()) return; TimeBar=time_0; CLOSEORDER("Buy"); } return; } //-------------------------------------------------------------------- void CLOSEORDER(string ord) { for(int i=PositionsTotal()-1; i>=0; i--) // returns the number of open positions if(m_position.SelectByIndex(i)) if(m_position.Symbol()==Symbol() && m_position.Magic()==m_magic) { if(m_position.PositionType()==POSITION_TYPE_BUY && ord=="Buy") m_trade.PositionClose(m_position.Ticket()); // Close Buy if(m_position.PositionType()==POSITION_TYPE_SELL && ord=="Sell") m_trade.PositionClose(m_position.Ticket()); // Close Sell } } //-------------------------------------------------------------------- void OPENORDER(string ord) { if(ord=="Sell") for(int i=PositionsTotal()-1;i>=0;i--) // returns the number of open positions if(m_position.SelectByIndex(i)) if(m_position.PositionType()==POSITION_TYPE_SELL) return; // Если sell, то не открываемся if(!m_trade.Sell(my_lot,Symbol(),m_symbol.Bid(),my_SL,my_TP,"")) Print("Buy -> false. Result Retcode: ",m_trade.ResultRetcode(), ", description of result: ",m_trade.ResultRetcodeDescription(), ", ticket of deal: ",m_trade.ResultDeal()); if(ord=="Buy") for(int i=PositionsTotal()-1;i>=0;i--) // returns the number of open positions if(m_position.SelectByIndex(i)) if(m_position.PositionType()==POSITION_TYPE_BUY) return; // Если buy, то не открываемся if(!m_trade.Buy(my_lot,Symbol(),m_symbol.Ask(),my_SL,my_TP,"")) Print("BUY_STOP -> false. Result Retcode: ",m_trade.ResultRetcode(), ", description of Retcode: ",m_trade.ResultRetcodeDescription(), ", ticket of order: ",m_trade.ResultOrder()); return; } double iMAGet(const int handle,const int index) { double MA[]; ArraySetAsSeries(MA,true); //--- reset error code ResetLastError(); //--- fill a part of the iMABuffer array with values from the indicator buffer that has 0 index if(CopyBuffer(handle,0,0,index+1,MA)<0) { //--- if the copying fails, tell the error code PrintFormat("Failed to copy data from the iMA indicator, error code %d",GetLastError()); //--- quit with zero result - it means that the indicator is considered as not calculated return(0.0); } return(MA[index]); } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ //+------------------------------------------------------------------+ //| Refreshes the symbol quotes data | //+------------------------------------------------------------------+ bool RefreshRates() { //--- refresh rates if(!m_symbol.RefreshRates()) return(false); //--- protection against the return value of "zero" if(m_symbol.Ask()==0 || m_symbol.Bid()==0) return(false); //--- return(true); } //+------------------------------------------------------------------+ //| Get Time for specified bar index | //+------------------------------------------------------------------+ datetime iTime(const int index,string symbol=NULL,ENUM_TIMEFRAMES timeframe=PERIOD_CURRENT) { if(symbol==NULL) symbol=Symbol(); if(timeframe==0) timeframe=Period(); datetime Time[]; datetime time=0; ArraySetAsSeries(Time,true); int copied=CopyTime(symbol,timeframe,index,1,Time); if(copied>0) time=Time[0]; return(time); } //+------------------------------------------------------------------+ //| Get value of buffers | //+------------------------------------------------------------------+ bool iGetArray(const int handle,const int buffer,const int start_pos, const int count,double &arr_buffer[]) { bool result=true; if(!ArrayIsDynamic(arr_buffer)) { PrintFormat("ERROR! EA: %s, FUNCTION: %s, this a no dynamic array!",__FILE__,__FUNCTION__); return(false); } ArrayFree(arr_buffer); //--- reset error code ResetLastError(); //--- fill a part of the iBands array with values from the indicator buffer int copied=CopyBuffer(handle,buffer,start_pos,count,arr_buffer); if(copied!=count) { //--- if the copying fails, tell the error code PrintFormat("ERROR! EA: %s, FUNCTION: %s, amount to copy: %d, copied: %d, error code %d", __FILE__,__FUNCTION__,count,copied,GetLastError()); //--- quit with zero result - it means that the indicator is considered as not calculated return(false); } return(result); } //+------------------------------------------------------------------+ Alexey Viktorov 2021.07.15 16:46 #13280 Yuriy Vins: 皆さんこんにちは、MT-5ストラテジーテスターの チャート上の十字線がどこでONになっているのか、あるいは全くないのか、ご存知の方はいらっしゃいますか? Ctrl+F ただし、ビジュアライゼーションによるテストの場合のみ。 1...132113221323132413251326132713281329133013311332133313341335...1503 新しいコメント 理由: キャンセル 取引の機会を逃しています。 無料取引アプリ 8千を超えるシグナルをコピー 金融ニュースで金融マーケットを探索 新規登録 ログイン スペースを含まないラテン文字 このメールにパスワードが送信されます エラーが発生しました Googleでログイン WebサイトポリシーおよびMQL5.COM利用規約に同意します。 新規登録 MQL5.com WebサイトへのログインにCookieの使用を許可します。 ログインするには、ブラウザで必要な設定を有効にしてください。 ログイン/パスワードをお忘れですか? Googleでログイン
MT5
複数のペアで同時にパラメータをオーバーシュートして最適化を実行できない。
テスターの「シンボル」で「マーケットウォッチから全てのシンボル」を選択すると、「パラメータ」タブで入力パラメータのオーバーシュートを設定する機能が無効になり、チェックボックスがチェックされず、値が入力されないだけです。どうしたらいいのでしょうか?
地域の皆様のお力をお借りしたいのですが...。
MT5
複数ペアで同時にパラメータをオーバーシュートして最適化を 行うことができませんでした。
テスターの「シンボル」欄で「マーケットウォッチから全てのシンボル」オプションを選択すると、「パラメータ」タブで入力パラメータのオーバーシュートを設定する機能が無効になり、ティックも値も入力されないだけになってしまいます。ど うしたらいいのでしょうか?
は数文字で最適化されていない、テストしただけで
は複数文字で最適化されていません。
そして、各シンボルのパラメータを個別にテストする必要があるのですか?
MT4でも同様です。MT5で多通貨のテストができるのは神話なんですか?
UPD しかし、ドキュメントには、明示的に:
各シンボルのパラメータを個別にテストする必要があるのでしょうか?
MT4でも同じように。MT5での多通貨テストは神話なんですか?
.....
テスト」と「最適化」という言葉の違いを理解していますか?
テスト」と「最適化」の違いを理解していますか?
キャラクターごとの テストなのか、最適化なのか。
だから、彼はオープンポジションについて知っておく必要がある。
トレーディング、自動売買システム、ストラテジーテストに関するフォーラム
初心者からのFAQ MQL5 MT5 MetaTrader 5
アレクサンドル・エゴロフ, 2021.07.14 18:04
mt5で各ペアの未決済注文の手数料を個別に計算 する方法を教えてください。はい、私のミスです。各ペアのポジションを列挙することで、)
皆さんこんにちは、MT-5ストラテジーテスターの チャート上の十字線はどこで有効になっているのか、また、そこにあるのかご存知の方はいらっしゃいますか?
マウスの中ボタン(スクロールホイールをクリック)
トレーリングストップを設定する方法を教えてくれる友達。
皆さんこんにちは、MT-5ストラテジーテスターの チャート上の十字線がどこでONになっているのか、あるいは全くないのか、ご存知の方はいらっしゃいますか?
Ctrl+F
ただし、ビジュアライゼーションによるテストの場合のみ。