int i=0; int judge=0; double zxshou=MarketInfo(sym,MODE_MINLOT); double factor=1; string symbol[20]; string symstr_fthf=""; string symstr_bkhf=""; string ss; symbol[0]="EUR";symbol[1]="GBP";symbol[2]="AUD";symbol[3]="CHF"; symbol[4]="JPY";symbol[5]="NZD";symbol[6...
Returns Close price value for the bar of specified symbol with timeframe and shift. doubleiClose( stringsymbol,// symbol inttimeframe,// timeframe intshift// shift ); Parameters symbol [in] Symbol name.NULLmeans the current symbol.
int i; string sym= Symbol(); double lot=0.1; int ticket; int huadian=10; int peri= PERIOD_CURRENT; int mag=1333; int check; double bandlow=iBands(sym,peri,20,2,0,PRICE_CLOSE,2,1); for(i=OrdersTotal()-1;i>=0;i--) { if(OrderSelect(i,SELECT_BY_POS)) { if(OrderSymbol()==...
double price_buy1=iHigh(sym,peri,iHighest(sym,peri,MODE_HIGH,20,1)); double price_sell1=iLow(sym,peri,iLowest(sym,peri,MODE_LOW,20,1)); double price_buy2=iHigh(sym,peri,iHighest(sym,peri,MODE_HIGH,55,1)); double price_sell2=iLow(sym,peri,iLowest(sym,peri,MODE_LOW,55,1))...
预定义函数:预定义函数带有一对括号,例如 iClose()、Symbol()。通过调用这些函数来执行特定的操作和功能,主要分为直接调用型和传入调用型两种。在上图中,Symbol就是直接调用型,可以直接获取到加载EA时当前图表的货币名称;而iClose()则是需要在括号内传入指定的数据,才能获取到需要数据的一种函数。
string sym= Symbol(); double lot=0.1; int ticket; int huadian=10; int peri= PERIOD_CURRENT; int mag=1333; int check; double bandlow=iBands(sym,peri,20,2,0,PRICE_CLOSE,2,1); for(i=OrdersTotal()-1;i>=0;i--) { if(OrderSelect(i,SELECT_BY_POS)) ...
temp1 = iMA(Symbol(), PERIOD_CURRENT, 均线, 0, 0, 0, i+1); // 给数组mk在i位置上赋空值, EMPTY_VALUE 就是空值 mk[i] = EMPTY_VALUE; if(Close[i] > temp0 && Close[i+1] < temp1) mk[i] = temp0; if(Close[i] < temp0 && Close[i+1] < temp1) mk[i] = temp0; ...
23、stotal164orderswap165ordersymbol165ordertakeprofit165orderticket166ordertype166window functions窗口函数167hidetestindicators隐藏指标167period使用周期167refreshrates刷新预定义变量和系列数组的数据167symbol当前货币对168windowbarsperchart可见柱总数168windowexpertname智能交易系统名称169windowfind返回名称169windowfirstvi...
Returns Close price value for the bar of specified symbol with timeframe and shift. doubleiClose( stringsymbol,// symbol inttimeframe,// timeframe intshift// shift ); Parameters symbol [in] Symbol name.NULLmeans the current symbol.
double price=iHigh(Symbol(),PERIOD_D1,0); ObjectCreate("highLine",OBJ_HLINE,0,0,price); price=iLow(Symbol(),PERIOD_D1,0); ObjectCreate("lowLine",OBJ_HLINE,0,0,price); ObjectSet("highLine",OBJPROP_COLOR,LimeGreen); // changing the color of the upper line ...