فتحت استاذي mr dollar أرجوالمساعدة من فضلك
Printable View
السلام عليكم
بحاول اعمل اكسبيرت يعمل على الاخبار
عاوز اعرف طريقه نقل معلومات من
ملف اكسيل الى ميتاتريدر حيث ملف الاكسيل هو المصدر
وليس الربط بين ميتاتريدر وملف الاكسل
جزاك لله خيرا
هذا هو نص الاكسبيرت , المطلوب فضلا لا أمرا ، ان الامر OrderOpenPrice يعمل في صفقة البيع ولا يعمل في صفقة الشراء
extern double Lots =1;
extern int StopLoss=0;
extern int TakeProfit=0;
extern int MagicNumber=1;
//+------------------------------------------------------------------+
int init()
{
//----
//----
return(0);
}
//+------------------------------------------------------------------+
int deinit()
{
//----
//----
return(0);
}
//+------------------------------------------------------------------+
double buy=0,sell=0;
//+------------------------------------------------------------------+
int start()
{
double SL,TP,C=Close[0];
//////////////////////////////////////////////////
double ma1,ma2,ma11,ma22;
ma1=iMA(NULL,0,100,0,MODE_EMA,PRICE_CLOSE,1);
ma11=iMA(NULL,0,100,0,MODE_EMA,PRICE_CLOSE,2);
ma2=iMA(NULL,0,10,0,MODE_EMA,PRICE_CLOSE,1);
ma22=iMA(NULL,0,10,0,MODE_EMA,PRICE_CLOSE,2);
////////////////////////////////////////////////////
//--------------------------------------------------------------------------------
if(OrderSelect(OrderTicket(), SELECT_BY_POS)==true)
//--------------------------------------------------------------------------------
/////////////////////شراء
if (C < OrderOpenPrice()*0.995 && buy==0
/*&& ma22<ma11&&ma2>ma1*/)
{
CloseSellOrders(); //اذا تحقق الشرط اغلق صفقة البيع وافتح صفقة شراء
double Buy_Order;
Buy_Order = OrderSend(Symbol(),OP_BUY,Lots,Ask,3,SL,TP,"GE",Ma gicNumber,0,clrWhite);
buy=1;
sell=0;
return(Buy_Order);
}
//--------------------------------------------------------------------------------
/////////////////////بيع
if (C > OrderOpenPrice()*1.005 && sell==0
/*&& ma22>ma11&&ma2<ma1*/)
{
CloseBuyOrders(); //اذا تحقق الشرط اغلق صفقة الشراء وافتح صفقة بيع
double Sell_Order;
Sell_Order=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,S L,TP,"GE",MagicNumber,0,Red);
buy=0;
sell=1;
return(Sell_Order);
}
return(0);
}
//+------------------------------------------------------------------+
void CloseBuyOrders()
{
for (int cnt = 0 ; cnt < OrdersTotal() ; cnt++)
{
OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
if (OrderMagicNumber() == MagicNumber && OrderSymbol()==Symbol())
{
if (OrderType()==OP_BUY)
{
OrderClose(OrderTicket(),OrderLots(),Bid,3);
}
}
}
}
void CloseSellOrders()
{
for (int cnt = 0 ; cnt < OrdersTotal() ; cnt++)
{
OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
if (OrderMagicNumber() == MagicNumber && OrderSymbol()==Symbol())
{
if (OrderType()==OP_SELL)
{
OrderClose(OrderTicket(),OrderLots(),Ask,3);
}
}
}
}
//+------------------------------------------------------------------+
وعليكم السلام ورحمة الله وبركاته
هذا مثال لدالة ستقوم بقراءة ملف أكسل وتعرض كل بياناته
كود PHP:
void ReadFile()
{
int file_handle=FileOpen(File_Name,FILE_CSV|FILE_WRITE|FILE_SHARE_READ|FILE_SHARE_WRITE,',');
if(file_handle!=INVALID_HANDLE)
{
Print("Start Reading");
while(!FileIsEnding(file_handle))
{
string str=FileReadString(file_handle,0);
Print(str);
}
}
FileClose(file_handle);
//---
}
السلام عليكم
مؤشر على الميتاستوك اريد اضافته كأسيبرت على ميتا تريدر 4 لينفذ اليا مع اشارات المؤشر ممكن طريقه العمل
وشكرا
السلام عليكم
كنت عايز اضيف مؤشر موجود على الميتاستوك كأسيبرت على ميتا تريدر 4 لينفذ اليا مع اشارات المؤشر
ممكن طريقه العمل
وشكرا
دى معادله مؤشر على ميتا ستوك اريد تحويلها الى اكسيبرت
وشكرا للاهتمام
Bull Power Bear Power 1
Trading signals for <Name> (<Symbol>) on <Date>
WriteIf(a:=(H-Mov(C,13,E))>0-(L-Mov(C,13,E));b:=(L-Mov(C,13,E))<0-(H-Mov(C,13,E));
state:=If(BarsSince(a)<BarsSince(b),1,0);
state>Ref(state,-1),"If trading short positions, exit all short positions today with a Market On Close (MOC) order or at the market price on tomorrow's open.
If trading long positions, enter long today with a Market On Close (MOC) order or at the market price on tomorrow's open. ")\
\
WriteIf(a:=(H-Mov(C,13,E))>0-(L-Mov(C,13,E));b:=(L-Mov(C,13,E))<0-(H-Mov(C,13,E));
state:=If(BarsSince(a)<BarsSince(b),1,0);
state<Ref(state,-1),"If trading long positions, exit all long positions today with a Market On Close (MOC) order or at the market price on tomorrow's open.
If trading short positions, enter short today with a Market On Close (MOC) order or at the market price on tomorrow's open. ")\
\
WriteIf(a:=(H-Mov(C,13,E))>0-(L-Mov(C,13,E));b:=(L-Mov(C,13,E))<0-(H-Mov(C,13,E));
state:=If(BarsSince(a)<BarsSince(b),1,0);
state=Ref(state,-1),"No trading signals today.")
The concept of Bull Power and Bear Power was developed and introduced by Alexander Elder. Bull Power is calculated by subtracting a 13-period exponential moving average from the high price. This is typically displayed as a histogram oscillating above and below the zero line. A higher reading above the zero line gives strength to the Bull Power. Bear Power is calculated by subtracting a 13-period exponential moving average from the low price. This is also typically displayed as a histogram oscillating above and below the zero line. A lower reading below the zero line gives strength to the Bear Power.
This system forces each indicator to use the same scaling method as the other. As long as the Bull Power is stronger above the zero line than the Bear Power strength is below the zero line, then a long position is maintained. If Bear Power strength below the zero line is greater than the Bull Power strength above the zero line, then a short position is maintained.
السلام عليكم اخي مستر دولار
ارجو كرما لا امرا كتابة كود برمجي لمعرفة زاوية السعر
مثلا
1.13904 وهو سعر افتتاح شمعة لليورو دولار
اريد كود زاوية 45 مثلا لهذا السعر
بحيث يعطيني سعر عند هذه الزاويه هل ممكن عمل ذلك
وشكرا مقدما
هذا رابط يشرح ايجاد الزاويه للقمه والقاع
اذا ممكن الكود لسعر الافتتاح وليس للقمه والقاع
يكون الكود حسب الموضوع المرفق في الرابط
زاوية السعر هى
جذر السعر
يضاف اليه معامل الزواية فى حالة بدء الحسابات من قاع نستبدل القاع بسعر الافتتاح او اللو
او يطرح منه معامل الزاوية فى حالة بدء الحسابات من قمة نستبدل القمه بسعر الافتتاح او الهاي
ثم تربيع الناتج
ملاحظه معامل الزاويه مشروح في الموضوع المرفق
ويكون للزاويه 45 هو0.25
السلام عليكم ورحمة الله وبركاته،
مرحبا أ. أسامة
أتمنى أنك بخير،
أنا أرسم مستويات الدعم والمقاومة يدوياً،
والأكسبرت يراقب سلوك السعر عند هذة المستويات،
تحديداً كيف أجعله يميز "الارتــــداد" من "الكســــر" كما في الصورة:
الملف المرفق 505373
إجمالاً تصنيف الأكسبرت لسلوك السعر بيكون واحد من الحالات الأربع:
اختراق مقاومة - ارتداد من مقاومة - كسر دعم - ارتداد من دعم
إضافة: أنا لا أحدد أي من هذة المستويات دعم وأيها مقاومة، بل على حسب موقع السعر حالياً،
أقرب مستوى له من أعلى هو المقاومة، وأقرب مستوى له من أسفل هو الدعم
شاكرة لك،،