A:=c>ref(c,1)*1.099 ;
买入条件:filter(A,1);
买入天数:=BArslAST(买入条件);
买入价:ref(c,买入天数),linethick0;
手续费:=0.003;
盈亏:100*((c-买入价)/买入价-手续费),linethick0,colore66878;
百分之5止赢:买入价*(1+0.05+手续费),linethick0,color000999;
百分之2止损:买入价*(1-0.025+手续费),coLORgreen,linethick0;
止赢条件:=H>百分之5止赢;
止赢天数:=BARSLAST(止赢条件);
止损条件:=c<百分之2止损;
止损天数:=BARSLAST(止损条件);
止赢:=买入天数> 止赢天数 and 止赢天数<止损天数;
{www.gUPaNg.com 股旁网_最新股票指标公式}
止赢天数2:=BARSLAST(止赢条件 and 止赢 and count(ref(止赢,1),1)=0);
止损:=买入天数>止损天数 and 止赢天数>止损天数;
止损天数2:=BARSLAST(止损 and count(ref(止损,1),1)=0);
drawtext(止赢 and count(ref(止赢,1),1)=0 and 买入天数<止损天数2,0.8,’止赢’);
drawicon(止赢 and count(ref(止赢,1),1)=0 and 买入天数<止损天数2,0.5,7);
drawtext(止损 and count(ref(止损,1),1)=0 and 买入天数<止赢天数2,0.4,’止损’);
drawicon(止损 and count(ref(止损,1),1)=0 and 买入天数<止赢天数2,0.6,8);
声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。
评论(0)