請教一下各位前輩,這個策略跑不出來,可以幫我看一下問題出在哪嗎?
value1=average(v,5)
value1=average(v,10)
value1=average(v,20)
input: FastLength(12), SlowLength(26), MACDLength(9);
variable: difValue(0), macdValue(0), oscValue(0);
SetTotalBar((maxlist(FastLength,SlowLength,6) + MACDLength) * 4);
SetInputName(1, "DIF短期期數");
SetInputName(2, "DIF長期期數");
SetInputName(3, "MACD期數");
MACD(weightedclose(), FastLength, SlowLength, MACDLength, difValue, macdValue, oscValue);
if oscValue[1] < 0 and oscValue > 0 then ret = 1;
1 評論