把23界周比赛状元有朋远来提到的”重心”公式改成通达信的
2019/12/15 18:31:24
公式编写说明:
重心:=AMOUNT/(V*100);两日重心:=(SUM(AMOUNT,2))/(SUM((V*100),2));三日重心:=(SUM(AMOUNT,3))/(SUM((V*100),3));四日重心:=(SUM(AMOUNT,4))/(SUM((V*100),4));上日重心:=ref(重心,1);上两日重心:=ref(两日重心,1);上三日重心:=ref(三日重心,1);上四日重心:=ref(四日重心,1);前日重心:=ref(重心,2);前两日重心:=ref(两日重心,2);前三日重心:=ref(三日重心,2);前四日重心:=ref(四日重心,2);DRAWTEXTREL(0,100,'■今日重心:'+重心),COLORGREEN;DRAWTEXTREL(85,100,'■两日重心:'+两日重心),COLOR0099ef;DRAWTEXTREL(0,150,'■三日重心:'+三日重心),COLORGREEN;DRAWTEXTREL(85,150,'■四日重心:'+四日重心),COLOR0099ef;DRAWTEXTREL(185,100,'■上日重心:'+上日重心),COLORGREEN;DRAWTEXTREL(270,100,'■上两日重心:'+上两日重心),COLOR0099ef;DRAWTEXTREL(185,150,'■上三日重心:'+上三日重心),COLORGREEN;DRAWTEXTREL(270,150,'■上四日重心:'+上四日重心),COLOR0099ef;DRAWTEXTREL(370,100,'■前日重心:'+前日重心),COLORGREEN;DRAWTEXTREL(455,100,'■前两日重心:'+前两日重心),COLOR0099ef;DRAWTEXTREL(370,150,'■前三日重心:'+前三日重心),COLORGREEN;DRAWTEXTREL(455,150,'■前四日重心:'+前四日重心),COLOR0099ef;
公式源码示例:
重心:=AMOUNT/(V*100);
两日重心:=(SUM(AMOUNT,2))/(SUM((V*100),2));
三日重心:=(SUM(AMOUNT,3))/(SUM((V*100),3));
四日重心:=(SUM(AMOUNT,4))/(SUM((V*100),4));
上日重心:=REF(重心,1);
上两日重心:=REF(两日重心,1);
上三日重心:=REF(三日重心,1);
上四日重心:=REF(四日重心,1);
前日重心:=REF(重心,2);
前两日重心:=REF(两日重心,2);
前三日重心:=REF(三日重心,2);
前四日重心:=REF(四日重心,2);
DRAWTEXT(CURRBARSCOUNT=100,10,'■今日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=89,10,CONST(重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=100,8,'■两日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=89,8,CONST(两日重心)),COLOR0099EF;
DRAWTEXT(CURRBARSCOUNT=100,6,'■三日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=89,6,CONST(三日重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=100,4,'■四日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=89,4,CONST(四日重心)),COLOR0099EF;
{-----------------------------------------------------------------------}
DRAWTEXT(CURRBARSCOUNT=70,10,'■上日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=58,10,CONST(上日重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=70,8,'■上两日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=58,8,CONST(上两日重心)),COLOR0099EF;
DRAWTEXT(CURRBARSCOUNT=70,6,'■上三日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=58,6,CONST(上三日重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=70,4,'■上四日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=58,4,CONST(上四日重心)),colorgreen;
{-----------------------------------------------------------------------}
DRAWTEXT(CURRBARSCOUNT=40,10,'■前日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=28,10,CONST(前日重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=40,8,'■前两日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=28,8,CONST(前两日重心)),COLOR0099EF;
DRAWTEXT(CURRBARSCOUNT=40,6,'■前三日重心:'),colorgreen;
DRAWNUMBER(CURRBARSCOUNT=28,6,CONST(前三日重心)),colorgreen;
DRAWTEXT(CURRBARSCOUNT=40,4,'■前四日重心:'),COLOR0099EF;
DRAWNUMBER(CURRBARSCOUNT=28,4,CONST(前四日重心)),COLOR0099EF;
3;
10;
看 股吧公式 www. kanguba.com
其它股票公式列表