3.5 ÑÕÉ«²ÎÊýÓ¦Ó㺓MACD”KÏß
¹«Ê½Ãû³Æ£ºMACDK
¼ò³Æ£º“MACD”KÏß
----------------------------
DIF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);
DEA:EMA(DIF,MID);
MACDDIF-DEA)*2,COLORSTICK;
D1:=EMA(C,3)-EMA(C,8);
D2:=EMA(O,3)-EMA(O,8);
D3:=EMA(H,3)-EMA(H,8);
D4:=EMA(L,3)-EMA(L,8);
DRAWICON(CROSS(D1,DIF) AND DIF<0 ,D4-0.1,10);
STICKLINE(D1>=D2,D1,D2,8,0),COLOR0055AA;
STICKLINE(D1<=D2,D1,D2,8,0),COLOR006600;
STICKLINE(D1>=D2,D1,D2,5,0),COLOR0077CC;
STICKLINE(D1>=D2,D1,D2,3,0),COLOR0099DD;
STICKLINE(D1>=D2,D3,D4,0,0),COLOR00BBFF;
STICKLINE(D1<=D2,D1,D2,5,0),COLOR009900;
STICKLINE(D1<=D2,D1,D2,3,0),COLOR00BB00;
STICKLINE(D1<=D2,D3,D4,0,0),COLOR00EE00;
------------------------------
ʾͼ
ÑÕÉ«²ÎÊý²»ÊǺ¯Êý£¬ËüÃèÊö´ý»Í¼ÐεÄÑÕÉ«£¬½«Æä²åÈ뵽ÿ¸öÖ¸±ê¹«Ê½ºóÃ棬ÓöººÅ·Ö¸ô¿ª¡£
³£ÓÃÑÕÉ«²ÎÊýÓУº ¡¾½»Ò×֪ʶÊÕ¼¯ÕûÀí¡¿
COLORBLACK ºÚÉ«
COLORBLUE À¶É«
COLORGREEN ÂÌÉ«
COLORCYAN ÇàÉ«
COLORRED ºìÉ«
COLORMAGENTA ÑóºìÉ«
COLORBROWN ×ØÉ«
COLORLIGHTGRAY µ»ÒÉ«
COLORGRAY Éî»ÒÉ«
COLORLIGHTBLUE µÀ¶É«
COLORLIGHTGREEN µÂÌÉ«
COLORLIGHTCYAN µÇàÉ«
COLORLIGHTRED µºìÉ«
COLORLIGHTMAGENTA µÑóºìÉ«
COLORYELLOW »ÆÉ«
COLORWHITE °×É«
ÑÕÉ«ÃèÊö·û»¹¿ÉÒÔ×Ô¶¨ÒåÑÕÉ«£¬¸ñʽΪCOLOR+“RRGGBB”£ºRR¡¢GG¡¢BB±íʾºìÉ«¡¢ÂÌÉ«ºÍÀ¶É«µÄ·ÖÁ¿£¬Ã¿·NÑÕÉ«µÄÈ¡Öµ·¶Î§ÊÇ00-FF£¬²ÉÓÃÁË16½øÖÆ¡£
ÀýÈ磺MA5£ºMA(CLOSE£¬5)£¬COLOR00FFFF±íʾ´¿ºìÉ«Óë´¿ÂÌÉ«µÄ»ìºÏÉ«£ºCOLOR808000±íʾµÀ¶É«ºÍµÂÌÉ«µÄ»ìºÏÉ«¡£
£¨²Î¼û¡¶¸½¼þ¡·--ÑÕÉ«´úÂë±í£©
3.6 ÐÂÔöº¯ÊýÓ¦Óã¨horcalc£©
º¯Êý£º HORCALC(X)
˵Ã÷£º Êý¾ÝÏî:100-HIGH,101-OPEN,102-LOW,103-CLOSE,104-VOL,105-ÕÇ·ù
¼ÆË㷽ʽ:0-ÀÛ¼Ó,1-ÅÅÃû´Î
ȨÖØ:0-×ܹɱ¾,1-Á÷ͨ¹É±¾,2-µÈͬȨÖØ,3-Á÷ͨÊÐÖµ
Ó÷¨£º HORCALC(°å¿éÃû³Æ,Êý¾ÝÏî,¼ÆË㷽ʽ,ȨÖØ)
ÀýÈ磺 HORCALC(\'×ÔÑ¡¹É\',103,0,1);ÒÔ×ÔÑ¡¹É°å¿é¹ÉƱµÄ×ܹɱ¾ÎªÈ¨ÖØ£¬ÒÔÊÕÅ̼ÛΪÊýÔ´½øÐÐÀÛ¼Ó¡£
¹«Ê½Ãû³Æ£º£ú£ä£ë£ø
¹«Ê½ÃèÊö£º×Ô¶¨Ö¸ÊýKÏß
²ÎÊý£º£¨×îСֵ£©£¨×î´óÖµ£©£¨È±Ê¡Öµ£©
#n: 1 100 10
---------------
¸ß:=HORCALC(\'ºþ±±°å¿é\',100,0,1);
¿ª:=HORCALC(\'ºþ±±°å¿é\',101,0,1);
µÍ:=HORCALC(\'ºþ±±°å¿é\',102,0,1);
ÊÕ:=HORCALC(\'ºþ±±°å¿é\',103,0,1);
×Ô¶¨KÏß: DRAWKLINE(¸ß,¿ª,µÍ,ÊÕ);
MA(×Ô¶¨KÏß,N);
---------------
¹«Ê½ËµÃ÷£º
£±£®ÓÃÓÚÖÆ×÷×Ô¶¨ÒåÖ¸Êý¡¢×ÔÉè°å¿éÖ¸ÊýKÏß¡£
£²£®ÏÈÖÆ×÷×Ô¶¨Òå°å¿é£¬“£Ã£ô£ò£ì£«£ú”£¬ÌîдºÃ°å¿éÃû³ÆºÍ¼ò³Æ£¨Êý×Ö£©£»
£³£®“°å¿éÃû³Æ”ÐëÓõ¥ÒýºÅ£¬Èç\'×ÔÑ¡¹É\'¡¢\'ׯ¹É\'£»
£´£®ÆðʼλΪ£±£°£°£°µã£¨ÏÂÔص½±¾µØÊý¾Ý£©£»
£µ£®°å¿éÄÚ²»Òªº¬ÓÐÌ«¶àµÄ¹ÉƱÊýÁ¿£¬ÒÔÃâÓ°ÏìËٶȣ»
3.7 ÐÂÔöº¯ÊýÓ¦Óã¨blocksetnum£©
º¯Êý£º BLOCKSETNUM(°å¿éÃû³Æ)
˵Ã÷£º ͳ¼Æ°å¿éÖйÉƱÊýÁ¿
Ó÷¨£º BLOCKSETNUM(°å¿éÃû³Æ)
×¢Ò⣺°å¿éÃû³ÆÒªÓõ¥ÒýºÅ ¡¾½»Ò×֪ʶÊÕ¼¯ÕûÀí¡¿
ÀýÈ磺 BLOCKSETNUM(\'ST°å¿é\')£¬·µ»Ø“ST°å¿é”ÊýÁ¿¡£
¹«Ê½Ãû³Æ£ºSTPM
¹«Ê½ÃèÊö£º¸ö¹ÉÔÚst°å¿éÄÚÅÅÃû
--------------
°å¿é¹ÉÊýÁ¿:BLOCKSETNUM(\'ST°å¿é\'),NODRAW;
STÕÇ·ùÅÅÃû:HORCALC(\'ST°å¿é\',105,1,2);
˵Ã÷£º
NODRAWÊDz»Êä³öÏßÐÍÖ»Êä³öÊýÖµÃüÁÓÃÓÚ¶àÖ¸±ê²»¼æÈÝ×ø±ê£»
³£ÓõÄÓï¾ä
1£©½ñÊÕÅ̶ÔÓÚNÈÕÄÚ×îµÍÊÕÅ̼۵ÄÕÇ·ù£¨%£©(c-llv(c,n))/llv(c,n)*100;
2£©½ñÊÕÅ̼۶ÔÓÚNÈÕ×î¸ßÊÕÅ̼۵ĵø·ù£¨%£©(HHV(C,N)-C)/HHV(C,N)*100;
3£©¹É¼ÛÔÚ¹ýÈ¥NÈÕÄÚß\ÐпռäµÄÏà¶ÔλÖà (C-LLV(L,N))/(HHV(H,N)-LLV(L,N))*100;
4£©¹É¼ÛÉÏ·½N1%ÖÁN2%´¦µÄ³ïÂ루%£©
aa:=winner(c+c*n2/100)*100;
bb:=winner(c+c*n1/100)*100;
aa-bb
5£©¹É¼ÛÏ·½N1%ÖÁN2%´¦µÄ³ïÂ루%£©
(winner(c-c*n1/100)-winner(c-c*n2/100))*100;
6£©ÊÕÅ̼ÛN%´¦µÄÌ×ÀÎÅÌ 100-(winner(c*N/100))*100;
7£©ÊÕÅ̼ÛN%´¦µÄ»ñÀûÅÌ winner(c*N/100)*100;
8£©ÏÂÓ°Ïß (MIN(O,C)-L)/L*100;
9£©ÉÏÓ°Ïß (h-max(o,c))/max(o,c)*100;
10£©±¾ÖÜÆÚµÄÕǵø·ù (c-ref(c,1))/ref(c,1)*100;
11£©Õñ·ù (h-l)/l*100;
12£©¾ùÏß½ð²æ£¨M.NΪ¾ùÏßÖÜÆÚ£© cross(ma(c,m),ma(c,n))
13£©¾ùÏ߶àÍ·ÅÅÁÐ
a1:=ma(c,n1);
a2:=ma(c,n2);
a3:=ma(c,n3);
a4:=ma(c,n4);
count(a1>a2 and a2>a3 and a3>a4,3);
14£© ¾ùÏß¿ÕÍ·ÅÅÁÐ
a1:=ma(c,n1);
a2:=ma(c,n2);
a3:=ma(c,n3);
a4:=ma(c,n4);
count(a1
aa:=ma(c,n);
bb:=ref(aa,2);
aa
aa:=ma(c,p1);
bb:=ma(c,p2);
cc:=ref(cross(bb,aa),n);
count(cc,m);
17£©½ñÈճɽ»Á¿´óÓÚNÈÕÒÔÀ´µÄ¾ùÁ¿ VOL>MA(VOL,N);
18£©µÍλÃܼ¯
A1:=COST(85);
A2:=COST(15);
A3:=A1-A2;
A4:=(A1+A2)/2;
A5:=A3/A4*100<10;
B1:=HHV(H,120);
B2:=LLV(L,120);
B3:=B1-B2;
B4:=(A4-B2)
19£©»»ÊÖÂÊ VOL/CAPITAL*100;
20£©NÈÕÓ¯¿÷
V1:=VOL/SUM(VOL,N);
V2:=DMA(CLOSE,V1);
V3: (CLOSE-V2)/V2*100;