📅  最后修改于: 2022-03-11 15:00:17.543000             🧑  作者: Mango
//--- input parameters price going up / down
MqlRates PriceInfo[];
string signal="";
//--- void OnTick()
//--- Get Array
string signal="";
MqlRates PriceArray[];
ArraySetAsSeries(PriceArray,true);
int Data = CopyRates(_Symbol,_Period,0,3,PriceArray);
//--- if is going up
if (PriceArray[1].close>PriceArray[2].close)
{
signal="buy";
}
//--- if is going down
if (PriceArray[1].close