求程序糾錯
作者:金字塔 來源:cxh99.com 發布時間:2015年09月24日
- 咨詢內容:
收盤價大于50根K線的最高價開多單,小于
50根K線的最小價開空單回抽17個點平倉,不會開單求程序糾錯
input:cc(50,10,150,5);
h_1:=hhv(h,enterbars+1);l_1:=llv(l,enterbars+1);hh:=hhv(h,cc);ll:=llv(l,cc);
kd:=c>hh;kk:=c<ll;
buy(kd and holding=0,1,market);buyshort(kk and holding=0,1,market);
if l<h_1-17 then sell(1,0,market);if h>l_1+17 then sellshort(1,0,market);
- 金字塔客服:
input:cc(50,10,150,5);
h_1:=hhv(h,enterbars+1);
l_1:=llv(l,enterbars+1);
hh:=hhv(h,cc);
ll:=llv(l,cc);
kd:=h>ref(hh,1);
kk:=l<ref(ll,1);
if h>l_1+17 then sellshort(1,0,market);
buy(kd and holding=0,1,market);
if l<h_1-17 then sell(1,0,market);
buyshort(kk and holding=0,1,market);
- 用戶回復:
感謝無所不能的版主