EA请求 - 页 2 1234 新评论 AlexPiechFinGeR 2005.11.17 12:45 #11 是 BETA 交易时间是ALPARI时间!!!! (GTM+1) #property copyright "Alex.Piech.FinGeR" #property link "https://www.forex-tsd.com" #define MAGIC 20051021 extern string PARAMETERS_TRADE = "PARAMETERS TRADE"; extern int SLIPPAGE = 3; extern double Lots = 0.1; extern int StopLoss = 10; extern int TakeProfit = 35; extern int JPYpair = 0; extern bool useProfitTrailing = False; extern int TrailingStop = 20; extern int TrailingStep = 3; extern string PARAMETERS_EXPERT = "PARAMETERS EXPERT"; extern bool UseOneAccount = False; extern int NumberAccount = 0815; extern string Name_Expert = "BETA"; extern bool UseSound = True; extern string NameFileSound = "expert.wav"; extern color clOpenBuy = LightBlue; extern color clOpenSell = LightCoral; extern color clModifyBuy = Aqua; extern color clModifySell = Tomato; extern color clCloseBuy = Blue; extern color clCloseSell = Red; int prevBar; void SetArrow(datetime t, double p, int k, color c) { ObjectSet("Arrow", OBJPROP_TIME1 , t); ObjectSet("Arrow", OBJPROP_PRICE1 , p); ObjectSet("Arrow", OBJPROP_ARROWCODE, k); ObjectSet("Arrow", OBJPROP_COLOR , c); } void deinit() { Comment(""); } void start() { SetArrow(Time[0],Low[0]-5*Point,241,Gold); //bx=False; //sx=False; Comment(""); if (UseOneAccount && AccountNumber()!=NumberAccount) { Comment("-UseOnAccount- Number"+AccountNumber()+" FAILED!"); return; } else Comment(""); CheckForOpen(); CheckForClose(); if (useProfitTrailing) TrailingPositions(); } void CheckForOpen() { double ldStop=0, ldTake=0; double close1=iClose(NULL,1440,1); double high1=iHigh(NULL,1440,1); double low1=iLow(NULL,1440,1); double close=iClose(NULL,1440,0); double high=iHigh(NULL,1440,0); double low=iLow(NULL,1440,0); double Pr = high1 + 1*Point; double Pr2 = low1 - 1*Point; int tradesignal2 = 0; int tradesignal2s = 0; if (JPYpair == 0) double val2 = (Pr - (MathFloor(close1*100) /100))*10000; else val2 = (Pr - MathFloor(close1))*100; if (val2 >= 15 && val2 <= 85) tradesignal2 = 1; if (JPYpair == 0) double val2a = (Pr2 - (MathFloor(close1*100) /100))*10000; else val2a = (Pr2 - MathFloor(close1))*100; if (val2a >= 15 && val2a <= 85) tradesignal2s = 1; int T=0; if(Hour()== 23 && Minute() == 30) T=1; if (!ExistPosition() && prevBar!=Bars) { if (T==1 && tradesignal2 == 1 && (high1 - low1) >= 100*Point && (high1 - close1 ) >= 25*Point ) { if (StopLoss!=0) ldStop=Pr-StopLoss*Point; if (TakeProfit!=0) ldTake=Pr+TakeProfit*Point; SetOrder(OP_BUYSTOP,Pr , ldStop, ldTake); prevBar=Bars; } if (T== 1 && tradesignal2s == 1 && (high1 - low1) >= 100*Point && (close1 - low1) >= 25*Point ) { if (StopLoss!=0) ldStop=Pr2+StopLoss*Point; if (TakeProfit!=0) ldTake=Pr2-TakeProfit*Point; SetOrder(OP_SELLSTOP, Pr2, ldStop, ldTake); prevBar=Bars; } } } //+------------------------------------------------------------------+ //| is MAGIC trade open ? | //+------------------------------------------------------------------+ bool ExistPosition() { bool Exist=False; for (int i=0; i<OrdersTotal(); i++) { if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) { if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC) Exist=True; } } return(Exist); } void SetOrder(int op, double pp, double ldStop, double ldTake) { color clOpen; string lsComm=GetCommentForOrder(); if (op==OP_BUYSTOP) clOpen=clOpenBuy; else clOpen=clOpenSell; OrderSend(Symbol(),op,Lots,pp,SLIPPAGE,ldStop,ldTake,lsComm,MAGIC,0,clOpen); if (UseSound) PlaySound(NameFileSound); } string GetCommentForOrder() { return(Name_Expert); } void TrailingPositions() { for (int i=0; i<OrdersTotal(); i++) { if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) { if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC ) { if (OrderType()==OP_BUY) { if ((Bid-OrderOpenPrice())>TrailingStop*Point) { if (OrderStopLoss()<Bid-(TrailingStop+TrailingStep-1)*Point) { ModifyStopLoss(Bid-TrailingStop*Point, clModifyBuy); } } } if (OrderType()==OP_SELL) { if (OrderOpenPrice()-Ask>TrailingStop*Point) { if (OrderStopLoss()>Ask+(TrailingStop+TrailingStep-1)*Point || OrderStopLoss()==0) { ModifyStopLoss(Ask+TrailingStop*Point, clModifySell); } } } } } } } void CheckForClose() { bool fs=False; bool fs1=False; int T2=0; if(Hour()== 13 && Minute() >= 45) T2=1; if (T2==1){ fs1 = True; fs = True; } for (int i=0; i<OrdersTotal(); i++) { if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) { if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC) { if (OrderType()==OP_BUYSTOP && fs) { OrderDelete(OrderTicket()); // OrderClose(OrderTicket(), Lots, Bid, SLIPPAGE, Aqua); return; } if (OrderType()==OP_SELLSTOP && fs1) { OrderDelete(OrderTicket()); // OrderClose(OrderTicket(), Lots, Ask, SLIPPAGE, Violet); return; } } } } } void ModifyStopLoss(double ldStop, color clModify) { bool fm; double ldOpen=OrderOpenPrice(); double ldTake=OrderTakeProfit(); fm=OrderModify(OrderTicket(), ldOpen, ldStop, ldTake, 0, clModify); if (fm && UseSound) PlaySound(NameFileSound); } EA request Cci_ea 基本问题... AlexPiechFinGeR 2005.11.18 14:33 #12 这里是EA 附加的文件: platinum.mq4 7 kb Sergey Golubev 2005.11.18 14:58 #13 亚历克斯。 Platimun和Beta的时间框架是什么? xpie 2005.11.18 15:03 #14 Eric: 萨达,我认为它的意思是,比如说。如果价格在1.1785到1.1799之间,不要做多(因为在 "整数 "处会有阻力--1.1800,它可能会回落)。 如果价格在1.1715到1.1701之间,不要做空(因为在 "整数 "处会有支撑--1.1700,它可能会回调)。 但我可能是错的! eric,我认为你错了,他的意思是 如果价格在1.1685到1.1715之间,不要做空或做多交易,因为他认为这是一个巨大的支撑或阻力区域。 xpie AlexPiechFinGeR 2005.11.18 22:30 #15 我有自动的D1日线图,所有的时间框架 是的,xpie是所有测试版,请帮助我。 Eric 2005.11.19 05:35 #16 xpie,是的,看起来你是对的 -- 多头和空头有一个30点的 "禁止交易区"。 lowphat 2005.11.26 19:03 #17 Alex.Piech.FinGeR: 是的,BETA 。 如果你愿意,你可以把它发到forextrash<--yahoo>上。 Yaroslav Gatalyak 2005.11.27 07:43 #18 EasyDayTrader 上的类似策略已可使用。看看吧。 sadaloma 2005.11.27 07:44 #19 forex-experts: EasyDayTrader 上的类似策略已经可以使用了。看看吧。 也许你可以发布一个EXP或EX4的试用版(30天)供我们试驾? 否则,人们可能会认为你在这里发帖只是为了宣传你的商业EA,而不是为了论坛成员的利益......这就叫免费的垃圾邮件,对吗?现在,我们不希望这样,不是吗? 这里有一个链接,我认为你未来的 "广告 "帖子应该放在这里(商业EA)。 https://www.mql5.com/en/forum/173061 萨达 编辑。 PS:我的帖子,读完后,听起来有点太讽刺了......如果我冒犯了你,很抱歉,但实际上我真的对测试商业EA感兴趣。 006 2006.02.28 17:12 #20 澄清一下 我认为他的意思是只有 在价格为80或以下时做空,20或以上时做多,最好是在这两个位置/附近,而不是在100点的中间。 1234 新评论 您错过了交易机会: 免费交易应用程序 8,000+信号可供复制 探索金融市场的经济新闻 注册 登录 拉丁字符(不带空格) 密码将被发送至该邮箱 发生错误 使用 Google 登录 您同意网站政策和使用条款 如果您没有帐号,请注册 可以使用cookies登录MQL5.com网站。 请在您的浏览器中启用必要的设置,否则您将无法登录。 忘记您的登录名/密码? 使用 Google 登录
是 BETA
交易时间是ALPARI时间!!!! (GTM+1)
#property copyright "Alex.Piech.FinGeR"
#property link "https://www.forex-tsd.com"
#define MAGIC 20051021
extern string PARAMETERS_TRADE = "PARAMETERS TRADE";
extern int SLIPPAGE = 3;
extern double Lots = 0.1;
extern int StopLoss = 10;
extern int TakeProfit = 35;
extern int JPYpair = 0;
extern bool useProfitTrailing = False;
extern int TrailingStop = 20;
extern int TrailingStep = 3;
extern string PARAMETERS_EXPERT = "PARAMETERS EXPERT";
extern bool UseOneAccount = False;
extern int NumberAccount = 0815;
extern string Name_Expert = "BETA";
extern bool UseSound = True;
extern string NameFileSound = "expert.wav";
extern color clOpenBuy = LightBlue;
extern color clOpenSell = LightCoral;
extern color clModifyBuy = Aqua;
extern color clModifySell = Tomato;
extern color clCloseBuy = Blue;
extern color clCloseSell = Red;
int prevBar;
void SetArrow(datetime t, double p, int k, color c) {
ObjectSet("Arrow", OBJPROP_TIME1 , t);
ObjectSet("Arrow", OBJPROP_PRICE1 , p);
ObjectSet("Arrow", OBJPROP_ARROWCODE, k);
ObjectSet("Arrow", OBJPROP_COLOR , c);
}
void deinit()
{
Comment("");
}
void start() {
SetArrow(Time[0],Low[0]-5*Point,241,Gold);
//bx=False;
//sx=False;
Comment("");
if (UseOneAccount && AccountNumber()!=NumberAccount) {
Comment("-UseOnAccount- Number"+AccountNumber()+" FAILED!");
return;
} else Comment("");
CheckForOpen();
CheckForClose();
if (useProfitTrailing) TrailingPositions();
}
void CheckForOpen() {
double ldStop=0, ldTake=0;
double close1=iClose(NULL,1440,1);
double high1=iHigh(NULL,1440,1);
double low1=iLow(NULL,1440,1);
double close=iClose(NULL,1440,0);
double high=iHigh(NULL,1440,0);
double low=iLow(NULL,1440,0);
double Pr = high1 + 1*Point;
double Pr2 = low1 - 1*Point;
int tradesignal2 = 0;
int tradesignal2s = 0;
if (JPYpair == 0)
double val2 = (Pr - (MathFloor(close1*100) /100))*10000;
else
val2 = (Pr - MathFloor(close1))*100;
if (val2 >= 15 && val2 <= 85) tradesignal2 = 1;
if (JPYpair == 0)
double val2a = (Pr2 - (MathFloor(close1*100) /100))*10000;
else
val2a = (Pr2 - MathFloor(close1))*100;
if (val2a >= 15 && val2a <= 85) tradesignal2s = 1;
int T=0;
if(Hour()== 23 && Minute() == 30) T=1;
if (!ExistPosition() && prevBar!=Bars) {
if (T==1 && tradesignal2 == 1 && (high1 - low1) >= 100*Point && (high1 - close1 ) >= 25*Point ) {
if (StopLoss!=0) ldStop=Pr-StopLoss*Point;
if (TakeProfit!=0) ldTake=Pr+TakeProfit*Point;
SetOrder(OP_BUYSTOP,Pr , ldStop, ldTake);
prevBar=Bars;
}
if (T== 1 && tradesignal2s == 1 && (high1 - low1) >= 100*Point && (close1 - low1) >= 25*Point ) {
if (StopLoss!=0) ldStop=Pr2+StopLoss*Point;
if (TakeProfit!=0) ldTake=Pr2-TakeProfit*Point;
SetOrder(OP_SELLSTOP, Pr2, ldStop, ldTake);
prevBar=Bars;
}
}
}
//+------------------------------------------------------------------+
//| is MAGIC trade open ? |
//+------------------------------------------------------------------+
bool ExistPosition() {
bool Exist=False;
for (int i=0; i<OrdersTotal(); i++) {
if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) {
if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC) Exist=True;
}
}
return(Exist);
}
void SetOrder(int op, double pp, double ldStop, double ldTake) {
color clOpen;
string lsComm=GetCommentForOrder();
if (op==OP_BUYSTOP) clOpen=clOpenBuy; else clOpen=clOpenSell;
OrderSend(Symbol(),op,Lots,pp,SLIPPAGE,ldStop,ldTake,lsComm,MAGIC,0,clOpen);
if (UseSound) PlaySound(NameFileSound);
}
string GetCommentForOrder() {
return(Name_Expert);
}
void TrailingPositions() {
for (int i=0; i<OrdersTotal(); i++) {
if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) {
if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC ) {
if (OrderType()==OP_BUY) {
if ((Bid-OrderOpenPrice())>TrailingStop*Point) {
if (OrderStopLoss()<Bid-(TrailingStop+TrailingStep-1)*Point) {
ModifyStopLoss(Bid-TrailingStop*Point, clModifyBuy);
}
}
}
if (OrderType()==OP_SELL) {
if (OrderOpenPrice()-Ask>TrailingStop*Point) {
if (OrderStopLoss()>Ask+(TrailingStop+TrailingStep-1)*Point || OrderStopLoss()==0) {
ModifyStopLoss(Ask+TrailingStop*Point, clModifySell);
}
}
}
}
}
}
}
void CheckForClose() {
bool fs=False;
bool fs1=False;
int T2=0;
if(Hour()== 13 && Minute() >= 45) T2=1;
if (T2==1){
fs1 = True;
fs = True;
}
for (int i=0; i<OrdersTotal(); i++) {
if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) {
if (OrderSymbol()==Symbol() && OrderMagicNumber()==MAGIC) {
if (OrderType()==OP_BUYSTOP && fs) {
OrderDelete(OrderTicket());
// OrderClose(OrderTicket(), Lots, Bid, SLIPPAGE, Aqua);
return;
}
if (OrderType()==OP_SELLSTOP && fs1) {
OrderDelete(OrderTicket());
// OrderClose(OrderTicket(), Lots, Ask, SLIPPAGE, Violet);
return;
}
}
}
}
}
void ModifyStopLoss(double ldStop, color clModify) {
bool fm;
double ldOpen=OrderOpenPrice();
double ldTake=OrderTakeProfit();
fm=OrderModify(OrderTicket(), ldOpen, ldStop, ldTake, 0, clModify);
if (fm && UseSound) PlaySound(NameFileSound);
}
这里是EA
亚历克斯。
Platimun和Beta的时间框架是什么?
萨达,我认为它的意思是,比如说。
如果价格在1.1785到1.1799之间,不要做多(因为在 "整数 "处会有阻力--1.1800,它可能会回落)。
如果价格在1.1715到1.1701之间,不要做空(因为在 "整数 "处会有支撑--1.1700,它可能会回调)。
但我可能是错的!eric,我认为你错了,他的意思是
如果价格在1.1685到1.1715之间,不要做空或做多交易,因为他认为这是一个巨大的支撑或阻力区域。
xpie
我有自动的D1日线图,所有的时间框架
是的,xpie是所有测试版,请帮助我。
xpie,是的,看起来你是对的 -- 多头和空头有一个30点的 "禁止交易区"。
是的,BETA 。
如果你愿意,你可以把它发到forextrash<--yahoo>上。
EasyDayTrader 上的类似策略已可使用。看看吧。
EasyDayTrader 上的类似策略已经可以使用了。看看吧。
也许你可以发布一个EXP或EX4的试用版(30天)供我们试驾?
否则,人们可能会认为你在这里发帖只是为了宣传你的商业EA,而不是为了论坛成员的利益......这就叫免费的垃圾邮件,对吗?现在,我们不希望这样,不是吗?
这里有一个链接,我认为你未来的 "广告 "帖子应该放在这里(商业EA)。
https://www.mql5.com/en/forum/173061
萨达
编辑。
PS:我的帖子,读完后,听起来有点太讽刺了......如果我冒犯了你,很抱歉,但实际上我真的对测试商业EA感兴趣。
澄清一下
我认为他的意思是只有 在价格为80或以下时做空,20或以上时做多,最好是在这两个位置/附近,而不是在100点的中间。