AOEA源码分享(HLV高低点指标部分)

avatar
· 阅读量 6,671

由于这里无法上传文件,这个EA是通用版本包括一个指标HLV和一个EA执行程序AOEA两个文件,从这个EA设计到成型发布,源码一直是公开的(在我所在的QQ群中),而且确实是有一些废柴在淘宝上要价叫卖的,所以今天就在这里分享发布,希望你们能够多多了解马丁策略,无论他是好也罢,坏也罢,十八般武艺精通一种就是天下无敌的存在。

这个指标用好了是可以用来界定趋势走向形态以及压力支撑位置的,包括上升、下降和震荡,自己去体会琢磨,你们会受益的。

###################源码部分
#property copyright ""
#property indicator_chart_window
#property indicator_buffers 4
#property indicator_color1 White
#property indicator_color2 Yellow
#property indicator_color3 White
#property indicator_color4 Yellow
//--- buffers
int bar=10000;
extern int m = 200;
extern double StopK = 0.618;
double ExtMapBuffer1[];
double ExtMapBuffer2[];
double ExtMapBuffer3[];
double ExtMapBuffer4[];
//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
//---- indicators
   SetIndexStyle(0,DRAW_LINE);
   SetIndexBuffer(0,ExtMapBuffer1);
   SetIndexStyle(1,DRAW_LINE);
   SetIndexBuffer(1,ExtMapBuffer2);
   SetIndexStyle(2,DRAW_LINE);
   SetIndexBuffer(2,ExtMapBuffer3);
   SetIndexStyle(3,DRAW_LINE);
   SetIndexBuffer(3,ExtMapBuffer4);
//----
   return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function                       |
//+------------------------------------------------------------------+
int deinit()
  {
//----
  
//----
   return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator iteration function                              |
//+------------------------------------------------------------------+
int start()
  {
   int    countedBars=IndicatorCounted();
   if(countedBars < 0)
       countedBars = 0;
   int i=0;
   int k = Bars - countedBars;
   for(i=0;i<=k;i++)
     {
        double llv=Low[iLowest(Symbol(),0,MODE_LOW,m,i)];
        double hhv=High[iHighest(Symbol(),0,MODE_HIGH,m,i)];
        ExtMapBuffer1[i]=llv;
        ExtMapBuffer2[i]=hhv;
        ExtMapBuffer3[i]=hhv-(hhv-llv)*StopK;
        ExtMapBuffer4[i]=llv+(hhv-llv)*StopK;
     }
   return(0);
  }
//+------------------------------------------------------------------+

风险提示:本文所述仅代表作者个人观点,不代表 Followme 的官方立场。Followme 不对内容的准确性、完整性或可靠性作出任何保证,对于基于该内容所采取的任何行为,不承担任何责任,除非另有书面明确说明。

喜欢的话,赞赏支持一下
avatar
回复 0

加载失败()

  • tradingContest