hh:=hhv(h,enterbars+1);
if hh>enterprice+5*mindiff and hh<enterprice+40*mindiff and c-enterprice<5*mindiff then sell(1,0,market);
if hh>enterprice+40*mindiff and c>enterprice+30*mindiff then sell(1,0,market);
空单的思路说一下
ll:=llv(l,enterbars+1);
if enterprice-ll>5*mindiff and enterprice-ll<40*mindiff and enterprice-clsoe<=5*mindiff then sellshort(1,0,thisclose);
if enterprice-ll>40*mindif and enterprice-close<=30*minff then sellshort(1,0,thisclose);
if enterprice-n>5*mindiff and n-enterprice<40*mindiff and enterprice-c<5*mindiff then sell(1,0,market);
if enterprice-n>40*mindiff and enterprice-c<=30*mindiff then sell(1,0,market);