我加載在1秒圖上應(yīng)用,
突破半小時內(nèi)最低價超過3點平多開空
突破半小時內(nèi)最高價超過3點平空開多
(當(dāng)前時間之前的半小時內(nèi))
開倉后有大于10點的利潤并且利潤回撤30%則平倉
循環(huán)執(zhí)行,未平倉不允許開倉
if l<ref(llv(l,30*60),1)-3 then begin
sell(1,0,market);
buyshort(holding=0,1,market);
end
if h>ref(hhv(h,30*60),1)+3 then begin
sellshort(1,0,market);
buy(holding=0,1,market);
end
if holding>0 and h-enterprice>10 and (hhv(openprofit,enterbars+1)-openprofit)/hhv(openprofit,enterbars+1)>0.3 then sell(1,0,market);
if holding<0 and enterprice-l>10 and (hhv(openprofit,enterbars+1)-openprofit)/hhv(openprofit,enterbars+1)>0.3 then sellshort(1,0,market);
測試的時候無數(shù)據(jù)??