老師好,下面是論壇里的帖子,其中:=(c-enterprice)/enterprice*100;100是什么意思啊;求指導(dǎo)。
win:=0;
win2:=0;
if holding > 0 and enterbars > 0 then
begin
win:=(c-enterprice)/enterprice*100; //記錄最大盈利
if win > maxprofit then
maxprofit:=win;
win2:=(maxprofit-win)/maxprofit*100; //最大盈利后的回調(diào)幅度
end
就是盈利比上開(kāi)倉(cāng)價(jià)再乘以100,樓上這種寫(xiě)法有點(diǎn)麻煩,您要實(shí)現(xiàn)什么?直接說(shuō)出您的需求。
[此貼子已經(jīng)被作者于2015/1/28 16:33:50編輯過(guò)]
謝謝老師!股指期貨,一分鐘周期
我想開(kāi)倉(cāng)后,盈利大于10點(diǎn)以上后,執(zhí)行回調(diào)盈利的60%以下平倉(cāng);
謝謝指導(dǎo);
多頭:holding>0 and hhv(h,enterbars+1)-enterprice>10 and (hhv(h,enterbars+1)-c)/hhv(h,enterbars+1)>0.6
空頭:holding<0 and enterprice-llv(l,enterbars+1)>10 and (c-llv(l,enterbars+1))/c>0.6
謝謝老師!