指标公式详细说明
好公式网(www.goodgongshi.com)告诉您:当前正要下载:赢亏百分比--BS成功率一目了解指标公式下载 通达信百分比
赢亏百分比--bs指标成功率一目了解
通达信新版本可以用,老版输出不能大于16条,可能用不了.一个计算 b s 类操盘系统的小工具,只在指标栏中占用1厘米多的空间.可以自动计算出自b点买入价到s点卖出价之间的赢亏百分比,红色代表赢利,绿色代表亏损."发"的意思代表赢利超过100&以上.这样操盘指标的成功率高低一目了然.下面的代码不能真接用,需加在你的操盘指标代码中.只需对前面两句买入和卖出条件代码修改一下合入你的指标中即可.其中第四句 d2:=floor(((c-ref(c,d))/ref(c,d))*100);存在一点小问题,至今也没找到原因.当买入价格与卖出价格相当时,出现了一个条件空白区,输出了所有信号,这点请大家注意,当出现一个看不清的数字时,大概代表是"0"的意思.如能有高手解决这个问题或有更简单的办法不胜感激.不会改指标的把你的代码发出来,我帮你改.
买入条件:=由你自己定义
卖出条件:=由你自己定义
d1:=barslast(买入条件);
d2:=floor(((c-ref(c,d1))/ref(c,d1))*100);
0.95,colorblack;
1.1,colorblack;
drawtext(卖出条件,1,if(d2=0,'0',drawnull)),colorwhite;
drawtext(卖出条件,1,if(d2>0 and d2<3,'2',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=3 and d2<7,'5',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=7 and d2<9,'8',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=9 and d2<12,'10',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=12 and d2<14,'12',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=14 and d2<17,'15',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=17 and d2<20,'18',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=20 and d2<23,'22',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=23 and d2<27,'25',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=27 and d2<31,'30',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=31 and d2<33,'32',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=33 and d2<36,'35',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=36 and d2<39,'38',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=39 and d2<43,'40',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=43 and d2<47,'45',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=47 and d2<50,'48',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=50 and d2<53,'50',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=53 and d2<58,'55',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=58 and d2<63,'60',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=63 and d2<68,'65',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=68 and d2<73,'70',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=73 and d2<78,'75',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=78 and d2<83,'80',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=83 and d2<88,'85',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=88 and d2<93,'90',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=93 and d2<97,'95',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=97 and d2<100,'99',drawnull)),colorred;
drawtext(卖出条件,1,if(d2>=100,'发',drawnull)),colorred;
drawtext(卖出条件,1,if(d2<=-1 and d2>-3,'2',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-3 and d2>-5,'3',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-5 and d2>-7,'5',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-7 and d2>-9,'7',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2=-9 ,'9',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-10 and d2>-12,'10',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-12 and d2>-14,'12',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-14 and d2>-16,'14',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-16 and d2>-18,'16',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-18 and d2>-20,'18',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-20 and d2>-23,'20',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-23 and d2>-26,'23',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-26 and d2>-28,'25',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-28 and d2>-33,'30',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-33 and d2>-35,'32',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-35 and d2>-39,'35',drawnull)),colorgreen;
drawtext(卖出条件,1,if(d2<=-39 and d2>-43,'40',drawnull)),colorgreen;
仅仅提供源码
>>>使用本站搜索工具可以找到更多“赢亏百分比--BS成功率一目了解指标公式下载 通达信百分比”