+ Reply to Thread
Results 1 to 3 of 3

Average networkdays and exclude rows with missing data

  1. #1
    Registered User
    Join Date
    04-13-2022
    Location
    USA
    MS-Off Ver
    Home and Student 2016
    Posts
    4

    Average networkdays and exclude rows with missing data

    Hello,

    I have a table with many dates, and I'd like to get the average NETWORKDAYS between various dates. However, I need to exclude rows in which column C is blank.

    sampleexcel.PNG

    In this example, I know that the answer I'm looking for is 50 days, and the obvious solution would be to use a helper column. However, I'd like to avoid that a) because the real data has a lot more data and would need many helper columns, and b) I'm trying to increase my Excel knowledge. I've been playing around with arrays for the first time, but not succeeding in finding a solution to this.

    Thanks!

    Edit: I should add that I'm working primarily in Google Sheets, where I was able to use

    HTML Code: 
    to get a result of 50, but when I expand it to include row 4, I get bad data (large negative number) because of the blank.
    Attached Files Attached Files
    Last edited by smeyel; 04-15-2022 at 10:15 AM.

  2. #2
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2016
    Posts
    5,891

    Re: Average networkdays and exclude rows with missing data

    Try this:

    =AVERAGE(ARRAYFORMULA(if(C2:C4>0,NETWORKDAYS(B2:B4,C2:C4),"")))

  3. #3
    Registered User
    Join Date
    04-13-2022
    Location
    USA
    MS-Off Ver
    Home and Student 2016
    Posts
    4

    Re: Average networkdays and exclude rows with missing data

    Ooof, of course. Seems like such a simple modification, but I had my brain stuck on trying to use an AVERAGEIF function. Thank you so much, this is exactly what I needed!

+ 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. Replies: 2
    Last Post: 09-28-2020, 03:35 AM
  2. [SOLVED] Average Percentage (weighted average) but I want to exclude N/A
    By mespinoza in forum Excel Formulas & Functions
    Replies: 20
    Last Post: 12-28-2015, 02:53 PM
  3. Calculate an average based on criteria. Exclude some rows.
    By doublejsk in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-13-2015, 10:08 AM
  4. How to calculate Average of daily data to fill missing values
    By mahjid in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-11-2013, 05:46 AM
  5. Average a range of data but exclude blank data
    By casket8014 in forum Excel General
    Replies: 4
    Last Post: 02-06-2012, 01:25 PM
  6. Replies: 7
    Last Post: 08-30-2011, 09:59 AM
  7. [SOLVED] Use networkdays INCLUDE weekends, Exclude holidays
    By ronnomad in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-16-2005, 01:00 PM

Tags for this Thread

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