去年有人問這個公式怎么改為同花順: 周K:MA("KDJ.K#WEEK"(9,3,3) ,5),LINETHICK2,COLORWHITE; 周D:=MA("KDJ.D#WEEK"(9,3,3) ,5),LINETHICK2,COLOR33FF99; 周J:MA("KDJ.J#WEEK"(9,3,3) ,5),LINETHICK2,COLORMAGENTA; 周金▲:DRAWTEXT(CROSS("KDJ.K#WEEK"(9,3,3),"KDJ.D#WEEK"(9,3,3)) ,0,'周▲'),COLORRED; 周死▼:DRAWTEXT(CROSS("KDJ.D#WEEK"(9,3,3),"KDJ.K#WEEK"(9,3,3)) ,92,'周▼'),COLORGREEN; 周金叉:IF(CROSS(周K,周D),90,0),LINETHICK3,COLORRED; DRAWTEXT(周金叉,80,'周叉'),; DRAWICON(CROSS(周K,周D),90,5); DRAWBAND(周K,RGB(100,0,0),周J,RGB(0,100,0)); /////////////////////////////////////////////////////////////////////// 同花順的跨周期引用格式不一樣,應如此“KDJ.k"(9,3,3)#WEEKDAY 簡單改一下語法就OK了,如下: 周K:MA("KDJ.K"(9,3,3)#WEEKDAY ,5),LINETHICK2,colorwhite; 周D:=MA("KDJ.D"(9,3,3)#WEEKDAY ,5),LINETHICK2,COLOR33FF99; 周J:MA("KDJ.J"(9,3,3)#WEEKDAY ,5),LINETHICK2,colormagenta; 周金▲:DRAWTEXT(CROSS("KDJ.K"(9,3,3)#WEEKDAY,"KDJ.D"(9,3,3)#WEEKDAY) ,0,'周▲'),colorred; 周死▼:DRAWTEXT(CROSS("KDJ.D"(9,3,3)#WEEKDAY,"KDJ.K"(9,3,3)#WEEKDAY) ,92,'周▼'),colorgreen; 周金叉:IF(CROSS(周K,周D),90,0),LINETHICK3,colorred; DRAWTEXT(周金叉,80,'周叉'),; DRAWICON(CROSS(周K,周D),90,5); DRAWBAND(周K,RGB(100,0,0),周J,RGB(0,100,0)); MA5:MA(CLOSE,5); MA10:MA(CLOSE,10); MA20:MA(CLOSE,20); 日EMA60:EMA(CLOSE,60); PARTLINE(日EMA60,日EMA60>REF(日EMA60,1),RGB(255,0,0),日EMA60 周EMA60:EMA(CLOSE,300); 引用周EMA60:"EMA引用.EXP2"(12,60)#WEEK,colormagenta; |
|