Gann Five Day pullback.afl
上传用户:shiqiang
上传日期:2009-06-12
资源大小:1289k
文件大小:2k
源码类别:

金融证券系统

开发平台:

Others

  1. //------------------------------------------------------------------------------
  2. //
  3. //  Formula Name:    Gann Five Day pullback
  4. //  Author/Uploader: Steve Wiser 
  5. //  E-mail:          slwiserr@erols.com
  6. //  Date/Time Added: 2001-07-05 19:24:18
  7. //  Origin:          
  8. //  Keywords:        
  9. //  Level:           basic
  10. //  Flags:           system,exploration
  11. //  Formula URL:     http://www.amibroker.com/library/formula.php?id=63
  12. //  Details URL:     http://www.amibroker.com/library/detail.php?id=63
  13. //
  14. //------------------------------------------------------------------------------
  15. //
  16. //  Uses Gann Five day pull back for buy signal.
  17. //
  18. //------------------------------------------------------------------------------
  19. /* Elliott Oscillator Indicator*/
  20. var0=Ma(A,5)-Ma(A,34);
  21. graph0=var0;
  22. graph0Style=6;
  23. graph1=0;
  24. graph1Color=5;
  25. Fivelow= ( Ref(L,-3)<Ref(L,-4) AND Ref(L,-4)<Ref(L,-5) AND Ref(L,-2)<Ref(L,-3))AND (Ref(L,-1)<Ref(L,-2)) AND (L<Ref(L,-1));
  26. var1=
  27. ((Ma(var0,5)>0 
  28. AND 
  29. Ma(C,3)<Ma(C,10))
  30. AND
  31.  LinRegSlope(C, 38)>.25) 
  32. AND
  33. (Fivelow
  34.  OR
  35.  (Ref(C,-2)==Inside() AND Ref(L,-1)<Ref(L,-2)AND L<Ref(L,-1))
  36. OR
  37.  (Ref(L,-3)<Ref(L,-4)AND Ref(C,-1)==Inside()AND L<Ref(L,-1))
  38. OR
  39. (Ref(L,-2)<Ref(L,-3))AND (Ref(L,-1)<Ref(L,-2)AND Inside()));
  40. Buy=var1;
  41. Sell=0;
  42. Filter=Buy;
  43. Filter= (Buy==1)  ;
  44. numcolumns = 7;
  45. column0 =ref(C+0.065,-1);
  46. column0format = 1.2;
  47. column0name = "Trigger Price";
  48. column1 = C;
  49. column1name = "Close       ";
  50. column1format = 1.2;
  51. column2 = ma(v,17);
  52. column2name = "17 Ma Vol   ";
  53. column2format = 1.0;
  54. column3 = ma(C,17)/ma(c,50);
  55. column3name = "% 17/50 ";
  56. column3format = 1.2;
  57. column3format = 1.2;
  58. column4= ma(c,17);
  59. column4name="17 C ma";
  60. column4format = 1.2;
  61. column4= ma(c,50);
  62. column4name="50 C ma";
  63. column4format = 1.2;
  64. Column5=var0;
  65. column5Name="Elliott Ocs";
  66. Column5Format=1.2;
  67. Column6=LinRegSlope(var0,5);
  68. Column6Name="LRS Elliott";
  69. Column6format=1.2;
  70. /*  End of Exploration Code. */