当前位置:→ 股海网飞狐公式 → 正文
  • 飞狐精品指标-黄金分割

  • 相关简介:C/C++ Code 复制内容到剪贴板 {01-黄金分割} input:N8(4,1,100),P1(5,1,100); 主线:=WMA(CLOSE,P1)*0.98; VAR1:=POW(CLOSE-主线,1); VAR2:=MA(VAR1,3); VAR3:=SQRT(VAR2); 阻力线:=主线+1.96*VAR3; 支撑线:=主线-1.96*VAR3; PARTLINE(主线REF(主线,1)AND阻力线支撑线,主线),LINETHICK3,color

  • 文章来源:择股网作者:股海网发布时间:2009-06-13浏览次数:下载次数:0

C/C++ Code复制内容到剪贴板
  1. {01-黄金分割}   
  2. input:N8(4,1,100),P1(5,1,100);   
  3. 主线:=WMA(CLOSE,P1)*0.98;   
  4. VAR1:=POW(CLOSE-主线,1);   
  5. VAR2:=MA(VAR1,3);   
  6. VAR3:=SQRT(VAR2);   
  7. 阻力线:=主线+1.96*VAR3;   
  8. 支撑线:=主线-1.96*VAR3;   
  9. PARTLINE(主线>REF(主线,1) AND 阻力线<>支撑线,主线),LINETHICK3,colorFF;   
  10. PARTLINE(主线<REF(主线,1),主线),LINETHICK2,colorFF0000;   
  11. DRAWICON(主线>REF(主线,1),主线,10);   
  12. N1:=SYSPARAM(3);   
  13. N:=N1-SYSPARAM(2)+1;   
  14. HH:=HHV(HIGH,N);   
  15. LL:=LLV(LOW,N);   
  16. 最高:HH[N1],colorFF;   
  17. 最低:LL[N1],colorFF;   
  18. 最低+(最高-最低)*0.191;   
  19. 最低+(最高-最低)*0.382;   
  20. 最低+(最高-最低)*0.5,colorFF00FF;   
  21. 最低+(最高-最低)*0.618;   
  22. 最低+(最高-最低)*0.809;   
  23. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  24. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.191,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*0.191,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  25. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.382,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*0.382,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  26. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.5,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*0.5,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  27. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.618,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*0.618,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  28. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.809,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*0.809,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  29. DRAWNUMBER(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*1,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),REF(最低+(最高-最低)*1,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),2),SHIFT110,colorFFFF;   
  30. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'000%↑'),colorFFFF;   
  31. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.191,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'19.1%↑'),colorFFFF;   
  32. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.382,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'38.2%↑'),colorFFFF;   
  33. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.5,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'50%↑'),colorFFFF;   
  34. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.618,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'61.8%↑'),colorFFFF;   
  35. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*0.809,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'80.9%↑'),colorFFFF;   
  36. DRAWTEXT(BARSCOUNT(CLOSE)=SYSPARAM(2),REF(最低+(最高-最低)*1,BARSLAST(BARSCOUNT(CLOSE)=SYSPARAM(2))),'100%↑'),colorFFFF;   
  37. VAR1:=WINNER(CLOSE);   
  38. VAR2:=VOL/CAPITAL;   
  39. VAR3:=VAR2/VAR1;   
  40. 财神线:=IF(VAR1<N1/100,VAR3,0);   
  41. DRAWICON(财神线>3,LOW,10),ALIGN5;   
  42. VAR1:=WINNER(CLOSE);   
  43. VAR2:=VOL/CAPITAL;   
  44. VAR3:=VAR2/VAR1;   
  45. 财神线:=IF(VAR1<N1/100,VAR3,0);   
  46. 财神到:=财神线;   
  47. DRAWICON(财神线<REF(财神线>1,1) AND 财神线>0.5 AND 财神线<1,HIGH,1),ALIGN5;   
  48. VAR1111:=FORCAST(CLOSE,5);   
  49. STICKLINE(CLOSE<OPEN,HIGH,LOW,1,0),color8800;   
  50. STICKLINE(CLOSE<OPEN,HIGH,LOW,0,0),colorFF00;   
  51. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,8,0),color8800;   
  52. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,7,0),color9900;   
  53. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,6,0),colorAA00;   
  54. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,5,0),colorBB00;   
  55. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,4,0),colorCC00;   
  56. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,3,0),colorDD00;   
  57. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,2,0),colorEE00;   
  58. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,1,0),colorFF00;   
  59. STICKLINE(CLOSE>=OPEN,HIGH,LOW,1,0),colorFF;   
  60. STICKLINE(CLOSE>=OPEN,HIGH,LOW,0,0),colorEEFF;   
  61. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,8,0),colorFF;   
  62. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,7,0),color22FF;   
  63. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,6,0),color44FF;   
  64. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,5,0),color66FF;   
  65. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,4,0),color88FF;   
  66. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,3,0),colorAAFF;   
  67. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2,0),colorCCFF;   
  68. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1,0),colorEEFF;   
  69. DRAWNUMBER(SYSPARAM(2)=BARPOS,CLOSE,FINANCE(33),2),ALIGN5;   
  70. DRAWTEXT(SYSPARAM(2)=BARPOS,CLOSE,'     -收益'),ALIGN5;   
  71. DRAWTEXT(BARPOS=SYSPARAM(2),HIGH,'\n所属块:'+BLKNAME),ALIGN4,colorFFFF;   
  72. STICKLINE(CLOSE<OPEN,HIGH,LOW,1,0),color8800;   
  73. STICKLINE(CLOSE<OPEN,HIGH,LOW,0,0),colorFF00;   
  74. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,8,0),color8800;   
  75. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,7,0),color9900;   
  76. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,6,0),colorAA00;   
  77. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,5,0),colorBB00;   
  78. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,4,0),colorCC00;   
  79. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,3,0),colorDD00;   
  80. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,2,0),colorEE00;   
  81. STICKLINE(CLOSE<OPEN,CLOSE,OPEN,1,0),colorFF00;   
  82. STICKLINE(CLOSE>=OPEN,HIGH,LOW,1,0),colorFF;   
  83. STICKLINE(CLOSE>=OPEN,HIGH,LOW,0,0),colorEEFF;   
  84. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,8,0),colorFF;   
  85. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,7,0),color22FF;   
  86. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,6,0),color44FF;   
  87. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,5,0),color66FF;   
  88. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,4,0),color88FF;   
  89. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,3,0),colorAAFF;   
  90. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2,0),colorCCFF;   
  91. STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1,0),colorEEFF;   
  92. VAR1:=(CLOSE+HIGH+LOW)/3;   
  93. CB:=MA(VAR1,4);   
  94. A1:=HHV(CB,18);   
  95. A2:=HHV(CB,41);   
  96. A3:=HHV(HIGH,62)*0.98;   
  97. B1:=LLV(CB,18);   
  98. B2:=LLV(LOW,62)*1.02;   
  99. MID:=MA(CLOSE,20);   
  100. UPPER:=MID+2*STD(CLOSE,20);   
  101. LOWER:=MID-2*STD(CLOSE,20);   
  102. VAR18:=EMA(CLOSE,3)-EMA(CLOSE,6)-(EMA(CLOSE,6)-EMA(CLOSE,12))*(-100);   
  103. VAR28:=EMA(VAR18,3);   
  104. VAR38:=EMA(CLOSE,3)-EMA(CLOSE,6)-(EMA(CLOSE,24)-EMA(CLOSE,36))*(-100);   
  105. VAR48:=EMA(VAR38,9);   
  106. VAR58:=CROSS(VAR18,VAR28);   
  107. VAR36:=CROSS(VAR28,VAR18);   
  108. STICKLINE(VAR36,OPEN,CLOSE,1.5,0),colorFFFFFF;   
  109. STICKLINE(VAR58,OPEN,CLOSE,8,0),colorFF;   
  110. STICKLINE(VAR58,OPEN,CLOSE-(CLOSE-OPEN)*0.33,8,0),colorFFFF;   
  111. STICKLINE(VAR58,OPEN,CLOSE-(CLOSE-OPEN)*0.66,8,0),LINETHICK2,colorFF00FF;   
  112. 拐点:=MA(CLOSE,N8);   
  113. 拐点1:=MA(CLOSE,N8);   
  114. GD1:=REF(COUNT(拐点<=REF(拐点,1),5)=5,1) AND 拐点>REF(拐点,1);   
  115. GD2:=REF(COUNT(拐点1<=REF(拐点1,1),5)=5,1) AND 拐点1>REF(拐点1,1);   
  116. DRAWICON(GD1,LOW*0.99,8);   
  117. DRAWICON(GD1,LOW*0.98,1);   
  118. MID:=MA(CLOSE,20);   
  119. UPPER:=MID+2*STD(CLOSE,20);   
  120. LOWER:=MID-2*STD(CLOSE,20);   
  121. V1:=(CLOSE-LOWER)/(UPPER-LOWER)*100;   
  122. V2:=V1-EMA(V1,5);   
  123. K1:=SUM(LLV(V2,4),4)/4;   
  124. V3:=EMA(V2,64)*10;   
  125. V4:=EMA(0.4*V2*(-1),3);   
  126. V5:=-1*EMA(V2,39)*10;   
  127. A:=V3>10;   
  128. B:=V2>V4;   
  129. D:=V5>10;   
  130. E:=V3<=10 OR V2<=V4 OR V5<=10;   
  131. KS:=(CLOSE-SMA(CLOSE,13,1))/SMA(CLOSE,13,1)*(-100);   
  132. RKS:=REF(KS,1);   
  133. MLS:=RKS/KS>1.23 AND RKS>13 AND CLOSE/REF(CLOSE,1)>1.03;   
  134. 开:=OPEN;   
  135. 高:=HIGH;   
  136. 低:=LOW;   
  137. 收:=CLOSE;   
  138. 超跌:STICKLINE(KS>13,高,低,0,1),LINETHICK2,colorFFFFFF;   
  139. 反弹:STICKLINE(MLS=1,高,低,0,1),LINETHICK2,colorFF00FF;   
  140. STICKLINE(KS>13,开,收,8,1),LINETHICK2,colorFFFFFF;   
  141. STICKLINE(MLS=1,开,收,8,1),LINETHICK2,colorFF00FF;   
  142. VAR1:=(REF(HIGH,1)+REF(LOW,1))/2;   
  143. VAR2:=(REF(HIGH,1)+REF(LOW,1))/2;   
  144. VAR3:=MA(CLOSE,27)+2*STD(CLOSE,27);   
  145. DRAWICON(CROSS(VAR2,VAR3),HIGH*1.035,3);   
  146. DRAWTEXT(CROSS(VAR2,VAR3),HIGH*1.02,''),colorFF00;   
  147. 上:=MA(HIGH,30)*1.15;   
  148. 中1:=MA(HIGH,3)*1.03;   
  149. 中2:=MA(LOW,3)*0.97;   
  150. 下:=MA(LOW,30)*0.85;   
  151. 上通道:=EMA(EMA(EMA(HIGH,5),5),5)*1.05;   
  152. DRAWTEXT(FILTER(HIGH>上通道 AND CLOSE<上通道,3),HIGH*1.04,'●逃'),colorEE00FF;   
  153. 短期乖离率:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;   
  154. 趋势:=5*SMA((CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*80,5,1)-3*SMA(SMA((CLOSE-LLV(LOW,7))/(HHV(HIGH,7)-LLV(LOW,7))*80,5,1),3,1)-SMA(SMA(SMA((CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*80,5,1),3,1),2,1);   
  155. 趋势1:=MA(MA(趋势,5),3);   
  156. 平衡线:=EMA(EMA(EMA(HIGH,3),3),1);   
  157. 回挡线:=平衡线*0.92;   
  158. DRAWICON(CROSS(趋势,0) AND 短期乖离率>3 AND 回挡线-REF(回挡线,1)>0,LOW,0);   
  159. 中期大底:D LLV(LOW,30)*1.01;   
  160. DRAWTEXT(LOW<=中期大底 AND 回挡线-REF(回挡线,1)>=-0.99999 AND CLOSE/OPEN>1.025,LOW,'买吧'),colorFFFF;   
  161. VAR2:=平衡线*0.84;   
  162. 了结线:=平衡线*1.06;   
  163. 主线:=WMA(CLOSE,8);   
  164. VAR1:=POW(CLOSE-主线,1);   
  165. VAR2:=MA(VAR1,3);   
  166. VAR3:=SQRT(VAR2);   
  167. WX:=MA(CLOSE,0);   
  168. M1:=MA(CLOSE,15)*(IF(20<5,WX,1));   
  169. M2:=MA(CLOSE,20)*(IF(20<7,WX,1));   
  170. DRAWTEXT(REF(CLOSE,1)<M2 AND 主线-REF(主线,1)>0 AND 了结线-REF(了结线,1)>0.01 AND LOW<M2 AND CLOSE>M2 AND M1-REF(M1,1)>0 AND CLOSE/OPEN>1.052,LOW-0.08,'★黄金'),colorFFFF;   
  171. MA10:=MA(CLOSE,10);   
  172. 平均值:=MA10/-10+MA10;   
  173. MX:=平均值*2*0.54;   
  174. MA13:=MA(CLOSE,13);   
  175. MA34:=MA(CLOSE,25);   
  176. DRAWTEXT(FILTER(上-REF(上,1)>0 AND 短期乖离率<-4 AND CLOSE<OPEN AND LOW<=MA34 AND CLOSE<MA13 AND MX-REF(MX,1)>0,1),LOW,'★破多买入'),colorFFFFFF;   
  177. 短期底:=LLV(HIGH,30)*0.93;   
  178. DRAWTEXT(LOW<=短期底 AND CLOSE<MX AND 短期乖离率>-8,LOW-0.15,'★涨20%'),colorFF00;   

 

 ☟问题反馈 ☞┄┄┄┄┄┄┄┄┄┄→收藏资源:

飞狐精品指标-黄金分割

  • 下载资源所需积分

    0

  • 当前拥有积分

    0

上传会员: 
股海网
文件大小: 
Bytes
上传时间: 
2009-06-13
下载积分: 
-
免责声明: 
请仔细阅读并同意后才能下载
本附件为用户分享上传,股海网没有对文件进行验证,不能保证下载资源的准确性、安全性和完整性,也不保证下载资源能正常安装和使用,且下载后扣除的积分无法退还,除非您充分理解并完全接受本声明,否则您无权下载。
本站对提供下载的软件、指标、资料等不拥有任何权利,其版权归该下载资源的合法拥有者所有。本附件仅供学习和研究使用,不得用于商业或者非法用途,如有侵犯您的版权, 请参看 《股海网侵权处理流程》《股海网免责声明条款》
点击下载无反应时,更换主流浏览器重新登录操作,如360浏览器、Edge浏览器、谷歌浏览器,个别浏览器有不兼容现象。
勾选以下表示您已经阅读并同意以上声明才能下载本文件,扣除积分无法退还!
我已阅读所有条款规定, 请点我同意 所有条款内容!我自愿下载!
提示:如下载失败,请点关闭刷新此页面或提交问题反馈给管理员→
关闭

关于我们 - 联系我们 - 隐私政策 - 免责声明 - 下载帮助 - 广告合作 - SiteMap - TOP
增值电信业务经营ICP许可证:湘B2-20210269 湘ICP备09016573号-10 湘公网安备43108102000040号
Copyright © 2021 铭网科技,All Rights Reserved.