#### Averaging List with Blank Cells

```Hi,

Someone gave me this formula to average the most recent five items in
a column of numbers:

=AVERAGE(OFFSET(B2,COUNTA(A:A)-5,0,5,1))

It works great unless the list has blank cells.  In that case it does
not work.

1.  6
2.
3.  7
4.  9
5.
6.   2
7.
8.   1
9.   23
10  4

How can I make it work when the columns have some blank cells?

Thanks,

Frank
```
 0
FrW22 (16)
12/17/2003 9:29:02 PM
excel.misc 78881 articles. 5 followers.

2 Replies
424 Views

Similar Articles

[PageSpeed] 1

```Try  =IF(count(A1:A10)=0,",Average(A1:A10))

>-----Original Message-----
>
>Hi,
>
>Someone gave me this formula to average the most recent
five items in
>a column of numbers:
>
>=AVERAGE(OFFSET(B2,COUNTA(A:A)-5,0,5,1))
>
>It works great unless the list has blank cells.  In that
case it does
>not work.
>
>1.  6
>2.
>3.  7
>4.  9
>5.
>6.   2
>7.
>8.   1
>9.   23
>10  4
>
>How can I make it work when the columns have some blank
cells?
>
>Thanks,
>
>Frank
>.
>
```
 0
anonymous (74722)
12/17/2003 9:54:30 PM
```Hi, thanks for the response.  Your formula doesn't work because if the
cell is blank it then counts that cell anyway.  I want to ignore cells
that are  blank.

1.  4
2.
3.  5
4.  6
5.
6.  4

If I have the formula set up to average the last three data points I
would get an answer of 5.  This is what I want.

1. 4
2.
3. 5
4. 6
5.
6. 4
7. 2

Now, on the next day when I input new data, the average of the last
three data points would be 4.

Thanks,

Frank

On Wed, 17 Dec 2003 13:54:30 -0800, "dave"
<anonymous@discussions.microsoft.com> wrote:

>Try  =IF(count(A1:A10)=0,",Average(A1:A10))
>
>
>>-----Original Message-----
>>
>>Hi,
>>
>>Someone gave me this formula to average the most recent
>five items in
>>a column of numbers:
>>
>>=AVERAGE(OFFSET(B2,COUNTA(A:A)-5,0,5,1))
>>
>>It works great unless the list has blank cells.  In that
>case it does
>>not work.
>>
>>1.  6
>>2.
>>3.  7
>>4.  9
>>5.
>>6.   2
>>7.
>>8.   1
>>9.   23
>>10  4
>>
>>How can I make it work when the columns have some blank
>cells?
>>
>>Thanks,
>>
>>Frank
>>.
>>

```
 0
FrW22 (16)
12/18/2003 7:38:46 AM

Similar Artilces:

Average formula where blank cells are counted as zeros
I am trying to write an average formula that takes into account the blank cells. I had only cells A2, A4, A6 filled out, but when I do =average(A1:A6), it is not treating the blanks as zeros so the answer is much higher than it should be. Should I do a logic formula within the cells? If you know the range, you could do the division yourself: =sum(a1:a6)/6 But this would include other non-numeric cells in the count of cells (6), too. krwelling wrote: > > I am trying to write an average formula that takes into account the blank > cells. > > I ha...

Find MAX data in sheet (Cell)
How would one go about finding the cell that contains the MAX info, o say any/all cells that exceeds 8,000 characters/spaces in a Excel page -- confuzedagai ----------------------------------------------------------------------- confuzedagain's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=2943 View this thread: http://www.excelforum.com/showthread.php?threadid=49148 1. Highlight the entire document 2. Select Format->Conditional Formatting 3. Select "Formula Is" 4. Input this formula =LEN(A1)>8000 5. Format with something obvious like green bac...

Using variable names for cells
I seem to remember a technique where I could assign a variable name to the contents of a cell so that whenever I wanted to use the contents, all I had to do was call up the variable name. Unfortunately I cannot find the way to set up the process. Any suggestsions or ideas would be appreciated. Thanks and a Happy New Year. -- Take out the trash to reply '05 FLHTCUI Hi dim rng as range set rng=activesheet.range("A1") msgbox rng.value -- Regards Frank Kabel Frankfurt, Germany Ultraglide wrote: > I seem to remember a technique where I could assign a variable name to >...

Cells not sorting right with other worksheets
I have some problems!!! First I have multiple worksheets in a workbook. And in one column that has some names. and the columns next to them has data which is yes/no go/ngo for each person. If I add a person it will update itself in each worksheet. But I need to sort it. So I sort it and it sorts fine in the worksheet I'm working in. But with the other worksheets it sorts it but the data for each person doesn't stay with the person... I hope I explained this problem to where someone can understand. PLEASE HELP!!! How do you have the referencews set between each worksheet? &qu...

How to find cells with links to other workbooks?

Summing cells in pivot tables
I have a problem summing cells in a pivot table. When I double-click on a cell that I want to add, the formula from that cell gets added. Eventually I run out of characters. Is there a way to switch how the cell gets picked up. I can manually enter the cell addresses that I am trying to sum but that takes forever. Thanks, Ted There are instructions here for adding the Generate GetPivotData button to a toolbar, and toggling the feature on and off: http://www.contextures.com/xlPivot06.html Ted wrote: > I have a problem summing cells in a pivot table. When I double-cli...

Conditional format if cell=0 then font colour same as background .
I have linked a cell from another sheet. If the original cell is blank, 0 shows in the linked cell (text would be typed in source cell). To handle this, I conditionally formatted the linked cell, so if it equals zero, the font colour is the same as the background colour of the cell so you can't see the zero But the zero still prints even though it is not showing prior to printing Try the formula =IF(Sheet1!F14="","",Sheet1!F14) in the linked cell. HTH Sandy -- to e-mail direct replace @mailintor.com with @tiscali.co.uk "Paligap" <Paligap@discu...

Refresh pivot chart when info in a cell changes
To all, I am looking for help with a Macro. What I ultimately want to do is refresh a pivot chart when the user makes a selection from a list (in a data validation cell). For example, I am an end user that selects my territory from a "drop down". The pivot chart will update to the information that is directly related to my territory. Thanks in advance for your help. Excel 2007, PivotTable With Table dependent drop-downs instead of data validation drop-downs. With non-event-driven macros. http://www.mediafire.com/file/ygzjqyi2j1x/03_09_10.xlsm ...

Display value of cell
Using Excel 2000 In a cell the formula shows instead of the value/result, how do I correct this? I want to see the formula. Reply to kdfoxca@yahoo.com Thanks. Are all formulas cells show the formulas or just one? Maybe you have a space before the = (Excel think it is text now) Or your cell is format as text -- Regards Ron de Bruin (Win XP Pro SP-1 XL2002 SP-2) www.rondebruin.nl "Kenya" <anonymous@discussions.microsoft.com> wrote in message news:050b01c3942b\$e28b7240\$a301280a@phx.gbl... > Using Excel 2000 > In a cell the formula shows instead of the value/resul...

Exporting distribution lists
Is thee any way to export distribution lists into something like a spreadsheet? Hello: Which version of Exchange are you using? In 5.5 it is easy to do. 200x is not as easy, but doable. Regards, Martin "Elbryyan" <elbryyan@hotmail.com> wrote in message news:483201c4a09c\$dd0a5240\$a301280a@phx.gbl... > Is thee any way to export distribution lists into > something like a spreadsheet? Do you keep all of your DGs in one OU? If so you can easily use LDIFDE or dsquery group. "Elbryyan" <elbryyan@hotmail.com> wrote in message news:483201c4a09c\$dd0a524...

Cell Reference #3
In a workbook, is it possible to know all the cells where a particular cell is referenced in a calculation. Specifically, if I make a change in one cell, what are all the cells that will be affected. ...

Maximum number of characters in a cell
Is there a way to format a cell so that it can contain more than 255 characters? Bill Hi Bill, > Is there a way to format a cell so that it can contain more than 255 > characters? A cell can contain about 32000 characters, but Excel will display only about a 1000 of them (depending on font and fontsize). Regards, Jan Karel Pieterse Excel MVP http://www.jkp-ads.com If you would add some forced (manual) line breaks (<Alt> <Enter>) in your text at opportune locations, you will find that you can *display* much more text. -- HTH, RD ----------------------------------...

merge cells with a twist
A B C joe @ domain.com trying to merge cells in a row so that column a(joe) b(@) c(domain.com) and that result is joe@domain.com Thank you. =A1&B1&C1 -- Regards, Peo Sjoblom (No private emails please) "jd" <jdumont@@novuscom.net> wrote in message news:uaAWelbgFHA.3436@tk2msftngp13.phx.gbl... >A B C > joe @ domain.com > > trying to merge cells in a row so that column a(joe) b(@) c(domain.com) > and > that result is joe@domain.com > Thank you. > > =hyper...

Deleting a word from a Cell
Hi Can anyone help, i am trying to deletel the last word from a Cell My cell currently read: - M04274059519 Total and I need a formula that will delete the "total" word Would really appreciate some help linexe On Jan 21, 7:27=A0am, Linexe <l.clark...@hotmail.co.uk> wrote: > Hi > > Can anyone help, i am trying to deletel the last word from a Cell > > My cell currently read: - =A0M04274059519 Total > > and I need a formula that will delete the "total" word > > Would really appreciate some help > > linexe C...

batch importing of mailing lists to Excel
I've got a mailing list of around 1000 names, stored in both Word and Entourage like this: First Name Last Name <e-mail address> Once I’ve eliminated the < >, do I then have to individually copy & paste (or type) all the info in three Excel columns? Or is there a simpler solution for batch importing of mailing lists to the Excel spreadsheet? "bgsignal" wrote: > I've got a mailing list of around 1000 names, stored in both Word and > Entourage like this: First Name Last Name <e-mail address> > Once I’ve eliminated the < >, do I then ...

referring cell in macro function
If a create a macro intended to be used as a function in a worksheet is there a property of the referring cell? I want to know what cell the formula is in. Dim callCell As String callCell = Application.Caller.Address Returns the cell address of the cell where the UDF is used. "zxcv" <zxcvnosend@yahoo.com> wrote in message news:aef3cafd-4c52-40a6-8348-ebf957b3abad@a21g2000yqn.googlegroups.com... > If a create a macro intended to be used as a function in a worksheet > is there a property of the referring cell? > > I want to know what cell the form...

time entery to the cell
any one can help me how to make the cell automatically take from the time of the computer... because i am using the timesheet tha can download from office online but the problem isour staff are key-in the correct time for there time in or time out... what i want is no need for them to enter the time, they just click the time in or time cell the time of the computer will be recorded to the cell.... Thanks a lot to all the expert that very helpfull..... jeff Hi see: http://www.mcgimpsey.com/excel/timestamp.html for entering a timestamp automatically then a cell changes -- Regards Frank ...

How do identify a blank cell in a formula
Example: IF(s69=blank,"Void".... What I want to say is if a cell, (s69in this example) is blank, enter the word "Void" but the above way don't work - I don't know how to enter that in this IF formula. Barb, here is one way =IF(ISBLANK(S69),"Void","") -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2002 & 2003 "Barb123" <Barb123@discussions.microsoft.com> wrote in message news:47...

Moving Average Formula Problem
I have a workbook with a date on worksheet 1 that indicates data has been entered for that month. On worksheet 2 is are columns of numbers with an average for each column at the bottom. I would like the average to use the date on worksheet 1 to calculate the average. The start of the range is known, but the end of the range is found only by looking up the date on worksheet 1. I have tried to use something like: =AVERAGE(B10:ADDRESS(VLOOKUP(date, range, 1, TRUE). This doesn't work and I can't find the functions needed to make it successful. Thanks in advance for any help! Needs...

Making cell change colour
Hi all I want to make a cell change colour 'on click'. Is there any way that this is possible? Help would be appreciated, Many thank darren --- Message posted from http://www.ExcelForum.com/ Hi this would require VBA / using an event procedure like Selection_change. Do you want to go this way? -- Regards Frank Kabel Frankfurt, Germany > Hi all > > I want to make a cell change colour 'on click'. > > Is there any way that this is possible? > > Help would be appreciated, > > Many thank > > darren > > > --- > Message posted f...

Using a value from a cell inside a formula!
Hi! I've got two cells that contain the start and end row of a matrix in sheet. I want to use these row numbers in a =COUNT.IF formula to count th number of specified instances in this matrix. But my problem is this; how can I use the values in the two cell inside the COUNT.IF formula?? I should look something like this; =COUNT.IF(F"cell1":F"cell2";"=argument") As you can see, the column (F) is specified in the formula but the ro number needs to be fetched from cell1 and cell2. Can anyone help me with the correct syntax? Thanks! -M -- marsupilam --...

Merged cells not copied properly
With some frequency, we have noted that cells are unmerged when copied. Generally speaking, we are copying a row and pasting it or inserting it in a new location. However, the clone is not always a clone, because the merged cells in the original are often unmerged either into smaller merged groups or into individual cells. Anyone have any idea what is going on here? ...

Distribution List Limits
Hi, I could find an answer to this for Outlook 2002 but not for Outlook 2003. Is the answer the same? We are using SBS 2003. The error is: "The distribution list has reached the maximum size for your network e-mail server. The new member could not be added." List was at 132 members. Not an Outlook question. These limits are set by the server, not Outlook. If your sever hasn't changed, then I imagine the limit is still the same. -- Russ Valentine [MVP-Outlook] "Paddy Ryan" <paddy@fpmt.org> wrote in message news:uOKDg0vaGHA.4196@TK2MSFTNGP03.phx.gbl... ...

Why won't contacts list out in address book
When I open my address book or select the To: or CC: options, my contacts are not listed out. I performed the steps at the below link. The address book appears to be linked to the contact folder since the address book shows the correct contact file in the very top and will search from it, but why aren't the contacts listed for easier selection like I've seen before? Thanks.. http://support.microsoft.com/default.aspx?scid=kb;en-us;287563&Product=ol2002 To give further info, I am running Outlook 2007 and the only message in either the global address list or my sp...