if holding>0 and h-enterprice>n*mindiff then sell(1,0,market);
if holding<0 and enterprice-l>n*mindiff then sellshort(1,0,market);