Right you are Flyboy...

Now that I have a Centered Moving Average with a blank 1/2 cycle period, I want 
to fill in the blank period with a "Derived Average". The Centered Average is 
plotted when there is a value for it, otherwise a "Derived Average" is plotted 
to fill in the blank period. The "Derived Average" would be a custom indicator.

Does AmiBroker  offer a way to splice on a new indicator (Derived Average) from 
the beginning of the blank period forward? ( I was able to do this in 
MetaStock).

Thanks


  ----- Original Message ----- 
  From: flyboypa30 
  To: amibroker@yahoogroups.com 
  Sent: Wednesday, September 01, 2010 3:41 PM
  Subject: [amibroker] Re: Moving Average


    
  Dennis,

  The idea of a "Centered" moving average is that it will show you "properly" 
the action of the moving average. BUT in order to do so, you will have to "give 
up" 1/2 of the length (period) of the moving average on the Hard Right Edge.

  The only other alternative is to use a Non Centered Moving average.

  To get a "Centered" Moving average to show values past the 1/2 period back 
shift, would require that your "predict" the values of what your moving average 
would be.

  A different approach would be to "shift" or "displace" the moving average the 
1/2 period forward to hopefully give you an idea on what might happen.

  Your Choice. None of them easy or perfect.

  Flyboy

  --- In amibroker@yahoogroups.com, "Dennis Lipter" <blackca...@...> wrote:
  >
  > Sorry...formula below doesn't do what I want.
  > 
  > This formula always shows a blank 9 bars when I scroll the chart. If I 
scroll the chart and there is data available 9 bars into the future, I want the 
formula to use that data so the average is plotted over the entire visible 
portion of the chart.
  > 
  > mp=IIf(C,(H+L+C)/3,(H+L)/2);
  > x=MA(mp,18);
  > Plot(x,"Centered ", colorRed, styleLine, Null, Null,-9);
  > 
  > I only want the first 9 bars of the entire plot to be blank, so when I 
scroll the chart, the blank bars disappear from view. I need to expand the 
sample data field 9 bars into the future, so when I scroll the chart, the blank 
portion of the plot disappears.
  > 
  > Hope this is clear.
  > 
  > Thanks
  > 
  > 
  > ----- Original Message ----- 
  > From: Dennis Lipter 
  > To: amibroker@yahoogroups.com 
  > Sent: Wednesday, September 01, 2010 11:47 AM
  > Subject: Re: [amibroker] Re: Moving Average
  > 
  > 
  > 
  > 
  > flyboypa,
  > 
  > This worked!
  > mp=IIf(C,(H+L+C)/3,(H+L)/2);
  > 
  > x=MA(mp,18);
  > 
  > Plot(x,"Centered ", colorRed, styleLine, Null, Null,-9);
  > 
  > Thanks!
  > 
  > 
  > ----- Original Message ----- 
  > From: flyboypa30 
  > To: amibroker@yahoogroups.com 
  > Sent: Wednesday, September 01, 2010 8:50 AM
  > Subject: [amibroker] Re: Moving Average
  > 
  > 
  > 
  > Dennis,
  > 
  > Try the following:
  > 
  > x = MA(mp,18);
  > 
  > Plot(x,"Centered ", colorred, styleline, null, null, -9);
  > 
  > This will do the "centering" of the MA in the Plot statement.
  >



  

Reply via email to