オジャラEA - ページ 14

 
Mohammed:
サラム

このバージョンを一緒にフォワードテストしていただけませんか?

設定 デフォルト

ペア 任意

TF: H4

MSN Style Pop Alertを使用する場合は、Coders Guru Pop Alertをダウンロードして ください。

http://www.metatrader.info/node/82

これは新しいバージョンですか、それとも何ですか?

 

飛び出せ!

BrunoFX:
hello Mohammed,

私はこの新しいが、なしでテストしたい。Coders Guru Pop Alert Plugin, but I have an error:

2;76;C:\ForexStrategyBuilderFX 400 400experts﹑Ojala.mq4;7:1;'Pop.mqh' - cannot open program file

Brunoさん、こんにちは。

もし、Coder Guru Popを使いたくないなら、このコードを使用してください。

//+------------------------------------------------------------------+

//| Ojala.mq4 |

//| Mohammed |

//| https://www.forex-tsd.com |

//+------------------------------------------------------------------+

#property copyright "Mohammed"

#property link "https://www.forex-tsd.com"

extern double TakeProfit=85;

extern double TrailingStop=10;

extern double StopLoss=35;

extern double Lots = 1; //0.01

extern int EmaPeriod = 6;

// Thanks going to Coders' Guru!

bool isNewSumbol(string current_symbol)

{

//loop through all the opened order and compare the symbols

int total = OrdersTotal();

for(int cnt = 0 ; cnt < total ; cnt++)

{

OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);

string selected_symbol = OrderSymbol();

if (current_symbol == selected_symbol)

return (False);

}

return (True);

}

//+------------------------------------------------------------------+

//| expert start function |

//+------------------------------------------------------------------+

int start()

{

//----

int cnt, ticket, total;

if(Bars<100)

{

Print("bars less than 100");

return(0);

}

if(TakeProfit<5)

{

Print("TakeProfit less than 10");

return(0); // check TakeProfit

}

total = OrdersTotal();

if(total < 1 || isNewSumbol(Symbol()))

{

if(iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,2)0)

{

ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-StopLoss*Point,Ask+TakeProfit*Point,"Ojala",12345,0,Green);

if(ticket>0)

{

if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES))

{

Print("BUY order opened : ",OrderOpenPrice());

}

}

else Print("Error opening BUY order : ",GetLastError());

return(0);

}

if(iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,2)>0 && iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,1)<0)

{

ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid+StopLoss*Point,Bid-TakeProfit*Point,"Ojala",12345,0,Red);

if(ticket>0)

{

if(OrderSelect(ticket,SELECT_BY_TICKET,MODE_TRADES))

{

Print("SELL order opened : " , OrderOpenPrice());

}

}

else Print("Error opening SELL order : ",GetLastError());

return(0);

}

return(0);

}

for(cnt=0;cnt<total;cnt++)

{

OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);

if(OrderType()<=OP_SELL && OrderSymbol()==Symbol())

{

if(OrderType()==OP_BUY) // long position is opened

{

if(iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,1)>0 && iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,0)<0)

{

OrderClose(OrderTicket(),OrderLots(),Bid,3,Violet); // close position

return(0); // exit

}

if(TrailingStop>0)

{

if(Bid-OrderOpenPrice()>Point*TrailingStop)

{

if(OrderStopLoss()<Bid-Point*TrailingStop)

{

OrderModify(OrderTicket(),OrderOpenPrice(),Bid-Point*TrailingStop,OrderTakeProfit(),0,Green);

return(0);

}

}

}

}

else // go to short position

{

if(iCustom(NULL,0,"EMAOsMA",EmaPeriod,0,1)0)

{

OrderClose(OrderTicket(),OrderLots(),Ask,3,Violet); // close position

return(0); // exit

}

if(TrailingStop>0)

{

if((OrderOpenPrice()-Ask)>(Point*TrailingStop))

{

if((OrderStopLoss()>(Ask+Point*TrailingStop)) || (OrderStopLoss()==0))

{

OrderModify(OrderTicket(),OrderOpenPrice(),Ask+Point*TrailingStop,OrderTakeProfit(),0,Red);

return(0);

}

}

}

}

}

}

return(0);

}

//+------------------------------------------------------------------+

 
JoZo:
これは新バージョンか何かですか?

Jozoです。

オリジナルのEAに少し手を加えて、より良く動くようにしたものです

 
Mohammed:
こんにちは、Bruno。もしCoder Guru Popを使いたくなければ、このコードを使用してください。

こんにちは、mohammedさん。

THX

 
Mohammed:
Jozoさん、オリジナルのEAに少し手を加えて、より良く動くようにしたものです

改造について教えてください。

ありがとうございます。

 
JoZo:
この修正について説明していただけますか?ありがとうございます

サラーム・ジョゾー!

以下は修正点です。

1-移動 平均の周期を12から6に変更しました。

2- 取引を開始する際の計算を、現在のバーではなく、前の2つのバーで行うようにしました。

3- StopLossが適用されました。

4- クロージングポジションが適用されました。

私の2日分の明細を添付します。(マニュアル2トレードは無視してください)。

ファイル:
 
Mohammed:
サラーム・ジョゾ

以下はその修正点です。

1- 移動平均の周期を12から6に変更しました。

2- 取引を開始するための計算は、現在のバーではなく、前の2つのバー(0バーではなく1および2)に対して行われます。

3- StopLossが適用されました。

4- クロージングポジションが適用されました。

私の2日分の明細書を添付します。(マニュアル2トレードは無視してください)。

本当に素晴らしい声明です。

私は2005年9月3日に古いオジャラをフォワードし始め、開始時の残高は1万ドルでした。今日は13.900円で、12kの資金でUSD/CHFが上がり、EURが下がるのを待っているところです。

新しいオジャラはどのタイムフレームで行うのでしょうか?

 
JoZo:
本当に素敵な文章ですね。

2005年3月9日に旧オジャラのフォワードを開始し、開始時の残高は1万円でした。今日で13.900ドル、エクイティは12kドルです。

新しいオジャラはどのTime Frameですか?

Jozoさん、ありがとうございます。

タイムフレームはH4 でなければなりません。

あなたのステートメントを見ることができますか?

 
Mohammed:
Jozoさん、ありがとうございます。

タイムフレームはH4 でなければならない

あなたのステートメントを見ることができますか?

こんにちは。

このEAは多通貨に対応する予定でしょうか、またその金額は?

 
BrunoFX:
こんにちは、このEAは多通貨に対応する予定ですか、そしていくらですか?

こんにちは。

ほとんどの通貨でテストしていますが、新しいEAでよりよく機能する最高の通貨を選択しませんでした(添付のワークスペースをご覧ください!)。

私はもうバックテストは 信じない、だからフォワードテストをしている。

ファイル:
screen.gif  53 kb
理由: