+ Reply to Thread
Results 1 to 13 of 13

Average formula that shows 0 but does not count in average

  1. #1
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Average formula that shows 0 but does not count in average

    Hi, I need some help with a dashboard I have created in the file attached, on the data tab in the week to date column I have a formula that calculates the average for each week on a rolling basis for that week ) so updates the week average as new data is entered for each day).

    This is shown on a speed dial on A I tab, my problem is that if I enter 0 for a days A I in data tab for the first day of the week, the week column does not pick it up and the speed dial still shows the last number above 0 from the previous week, but if I add the Iferror at the start of my formula it shows the 0 until the end of the year and the speed dial picks that up.

    I would like the week to date column to display o from the last 24hr column and show on speed dial but not count 0 in the average in the week to date column - if this is possible please. Hope this is clear.
    Password is dashboard
    Thanks
    Lewster
    Attached Files Attached Files
    Last edited by Lewster; 11-11-2015 at 04:44 AM.

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,986

    Re: Average formula that shows 0 but does not count in average

    Can you be a bit more specific about EXACTLY where the problem is? What cell(s) contain the problem formula and finally, unlock the sheet so that we can select the cell(s) and see what the formula is!!!!!!!
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    The problem is in the the week to date column on data tab (D5:D375), it does not pick up 0 if 0 is entered in to C12, as the formula for average states >0 but due to this the week to date speed dial on A I tab shows the previous week A I until a number >0 is entered. So if i enter 0 into C12 i would like D12:D18 to show 0 but not count it as part of the average.

    Password for all tabs is dashboard

    Thanks

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,986

    Re: Average formula that shows 0 but does not count in average

    I'm not sure if I fully understand what you want, but try:

    =IF(C5="","",IF(C5=0,0,AVERAGEIFS($C$5:C5,$C$5:C5,">0")))

  5. #5
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    Thank you Glenn that seems to be working, now I have to apply that to each week for each plant, may take a while.
    Lewster.

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,986

    Re: Average formula that shows 0 but does not count in average

    Great! I'm glad to have helped! If that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

    It'd also be appreciated if you were to click the Add Reputation button at the foot of any of the posts of all members who helped you reach a solution.

  7. #7
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    Sorry I was a little quick there, I would like it to do the average as a rolling average but when I enter 0 it shows 0 in the week to date instead of the rolling average and it will not let me add conditional formatting to the last day of the week.
    Lewster

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,986

    Re: Average formula that shows 0 but does not count in average

    OK... Still not clear - so another stab in the dark!!

    =IF(C5="","",IF(C5=0,IF(ISNUMBER(D4),D4,0),AVERAGEIFS($C$5:C5,$C$5:C5,">0")))

  9. #9
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    This works to some extent,
    Could you please explain the formula? Do not understand why D4 is there as D4 is text and if I change to D5 I get a circular reference warning ---(ISNUMBER(D4),D4,0), then when I go into the next week D12 the ISNUMBER references to D11 and puts number in D11 into D12??
    Last edited by Lewster; 11-11-2015 at 06:56 AM.

  10. #10
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,986

    Re: Average formula that shows 0 but does not count in average

    It was done to take account of the first cell in the column. If instead of IF(ISNUMBER(D4),D4,0) you just have D4, it copies the number from above if there's a zero on column C. That's fine, unless the entire column C starts with a zero. In that particular case it would copy the column header into D, which is incorrect!! Instead, the formula copies the number from the cell above, providing what is in the cell above is actually a number or zero, if it isn't.

  11. #11
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    Could I make D4 into $D$4?? so it is the same in all cells??

  12. #12
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    I have added a smaller sample file showing what I have and what I want it to look like. Just so I can try to help you understand my needs.

    Thanks

    Lewster
    Attached Files Attached Files

  13. #13
    Forum Contributor
    Join Date
    06-15-2014
    Location
    The great border City of Carlisle, England
    MS-Off Ver
    2010
    Posts
    123

    Re: Average formula that shows 0 but does not count in average

    Thanks Glenn I have solved it using your latter formula and a bit of adjusting:
    =IF(C5="","",IF(C5=0,IF(ISNUMBER(D4),D4,0),AVERAGEIFS($C$5:C5,$C$5:C5,">0")))
    then copy down for week 1

    for the 1st day of the next week
    =IF(C12="","",IF(C12=0,IF(ISNUMBER(D4),D4,0),AVERAGEIFS($C$12:C12,$C$12:C12,">0")))

    for the 2nd day of the week
    =IF(C13="","",IF(C13=0,IF(ISNUMBER(D12),D12,0),AVERAGEIFS($C$12:C13,$C$12:C13,">0")))
    and copied down for rest of the week
    and followed this pattern for the 52 weeks
    This gave me: any 0 entered in column C were shown in column D (average column) but not counted in the average for the week, this now allows 0 in Column D to be shown on the weekly average speed dial which was not happening before.
    Many thanks
    Lewster

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] need formula to average cells but if one cell has N/A then dont average and input N/A
    By CityInspector in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-08-2013, 04:16 PM
  2. [SOLVED] Count and average formula needed to not count text field
    By excelteam777 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-07-2013, 05:30 PM
  3. Replies: 0
    Last Post: 01-22-2013, 12:22 PM
  4. Average Formula Not Working - Nothing Shows Up
    By Jenniferh05 in forum Excel General
    Replies: 16
    Last Post: 06-23-2012, 09:35 AM
  5. Replies: 4
    Last Post: 11-19-2010, 10:49 AM
  6. Formula to Count Multiple Ifs and take an Average.
    By Sam_D in forum Excel General
    Replies: 11
    Last Post: 10-19-2009, 06:48 AM
  7. Average and Count formula
    By ExcelNewby in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-05-2007, 07:40 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1