Thread: averaging cells
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Ravens Fan Ravens Fan is offline
external usenet poster
 
Posts: 27
Default averaging cells

No it didn't work. It still returns 351 to the cell.
--
Baltimore Ravens


"Bernard Liengme" wrote:

I cannot get the same results that you have. But this should work
=IF(ISBLANK(A1),"", your_formula)
Of course it need to be array entered with SHIFT+CTRL+ENTER
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"Ravens Fan" wrote in message
...
Here is my dilemma. I am averaging only the last three times something has
been produced. Sometimes months go by with no production. On those months
I
donot want to show a average (since it did not run). The formula I'm using
averages three months of production and skips the blank months, but, it
still
shows and average. I'm hoping someone can manipulate my formula and show
me
how to put no data in months where there was no production.

This is the formula I'm using:

=AVERAGE(INDEX(A1:A100,LARGE(IF(A1:A100<"",ROW(A1 :A100)-ROW(A1)+1),MIN(C
OUNT(A1:A100),3))):INDEX(A1:A100,MATCH(9.999999999 99999E+307,A1:A100)))

Column "A" (actual Rate) is what I want to average and column "B" (3
month
avg) is the answer to my formula. As you can see, after the first 2 months
of
data the average repeats it's self. Is there a way to make it return a
blank
cell if no production was in that month. Example: Under "3 Month Avg." it
should read 366, 351 and then blank cells till you get to the next
production
month of 323 out of column "A". I hope this isn't to confusing and any
help
will be greatly appreciated.
Note: These numbers will be charted, so I need to have blank cells not 0.

Actual Rate for 3 Mo Avg 3 Month Avg.
366 366
337 351
351
351
351
351
351
323 342
331 330
358 337
356 348
348
300 338
338
306 321
321



--
Baltimore Ravens