Ciclo de datos: ciclos múltiples
Backtest puede elegir los futuros de OKEX
Contrato: este_contrato semana
Diagrama principal: Ninguno
Diagrama secundario: VJQ, fórmula de cálculo: VJQ: EMA (V* (C-REF (C, NC))
(*backtest start: 2018-04-01 00:00:00 end: 2018-05-28 00:00:00 period: 1h exchanges: [{"eid":"Futures_OKCoin","currency":"BTC_USD"}] args: [["N",100],["MINAMOUNT",10],["TradeAmount",10,126961],["ContractType","this_week",126961]] *) LOTS:=MAX(MINAMOUNT,INTPART(MONEYTOT/O * 0.8)); VJQ:EMA(V*(C-REF(C,NC)),N); B:=VJQ>0; S:=VJQ<0; BUYPK:=BARPOS>N AND BKVOL=0 AND B AND H>=HHV(H,N); SELLPK:=BARPOS>N AND SKVOL=0 AND S AND L<=LLV(L,N); BUYP:=SKVOL>0 AND B; SELLP:=BKVOL>0 AND S; // 入场 // Enter SELLPK,SPK(LOTS); BUYPK,BPK(LOTS); // 出场 // Leave BUYP,BP(SKVOL); SELLP,SP(BKVOL); // 止损 // Stop loss C>=SKPRICE*(1+SLOSS*0.01),BP(SKVOL); C<=BKPRICE*(1-SLOSS*0.01),SP(BKVOL); AUTOFILTER;