doubleiMA( stringsymbol,// symbol name inttimeframe,// Timeframe intma_period,//period intma_shift,// 平均数的转变 intma_method,// 平均方法 intapplied_price,//价格类型 int shift//shift );
doubleiMA( stringsymbol,// symbol name inttimeframe,// Timeframe intma_period,//period intma_shift,// 平均数的转变 intma_method,// 平均方法 intapplied_price,//价格类型 int shift//shift );
你好,我有一个类似的情况,我想在不使用拐杖的情况下解决这个问题。专家顾问开了一个头寸,并有一个止损和止盈。有一种情况是,在对一根蜡烛进行测试时(也就是满足开仓 条件时),在第一笔订单关闭后,马上就有第二笔、第三笔等订单被打开。这是由于在这根蜡烛上,开仓的条件得到了满足,一段时间后,止损或止盈指令被触发(开仓的条件仍然得到满足,蜡烛没有被关闭)。
你好,我有一个类似的情况,我想在不使用拐杖的情况下解决这个问题。专家顾问开了一个头寸,并有一个止损和止盈。有一种情况是,在对一根蜡烛进行测试时(也就是满足开仓 条件时),在第一笔订单关闭后,马上就有第二笔、第三笔等订单被打开。这是由于开仓的条件在那根蜡烛上得到满足,而止损或止盈指令在一段时间后触发(开仓的条件仍然得到满足,蜡烛没有被关闭)。
这里有一个例子,说明你如何使用它...
按日期检查是否有未结头寸,以及是否在该蜡烛上开仓和平仓...
下面是一个如何使用它的例子...
参考文献中的标准代码不起作用
https://docs.mql4.com/ru/basis/types/casting
带来简单结构类型的数据
如何治疗?
用于转换不同基本类型的值。例如,有一个数组uchar arr[].我们需要将double的值写到某一位置。
void GetBytes(double x,uchar &arr[],int pos)
或反之亦然。
double GetDouble(uchar &arr[],int pos)
也许有人会提出一个更简单的解决方案。
doubleiMA(
stringsymbol,// 符号名称
inttimeframe,// 时间框架
intma_period,//周期
intma_shift,//转移平均数
intma_method,// averaging method
intapplied_price,//价格类型
intshift// shift
)。
doubleiMA(
stringsymbol,// symbol name
inttimeframe,// Timeframe
intma_period,//period
intma_shift,// 平均数的转变
intma_method,// 平均方法
intapplied_price,//价格类型
int shift//shift
);
"欧元兑美元"
"欧元兑美元"
它是用倒逗号写的,谢谢你
doubleiMA(
stringsymbol,// symbol name
inttimeframe,// Timeframe
intma_period,//period
intma_shift,// 平均数的转变
intma_method,// 平均方法
intapplied_price,//价格类型
int shift//shift
);