DaveMacdonald
Board Regular
- Joined
- Nov 28, 2013
- Messages
- 52
- Office Version
- 365
- Platform
- Windows
Version: Excel Online
I want an average of the time (in days) between two milestones for many different people (one person per row), but I want the formula to ignore that row if there isn't a date in BOTH date cells, since it throws off the average in a major way.
Example "TABLE_1"
Current Formula =SUMPRODUCT(TABLE_1[MILESTONE 2]-TABLE_1[MILESTONE 1])/COUNT(TABLE_1[MILESTONE 2])&" Days"
As long as both milestone 1 and 2 are populated, the formula works great, but if milestone 1 is populated and milestone 2 isn't, then it throws the whole thing off. How would I write a formula where if row 5 as above has a blank, then neither columns 2 or 3 for that row are part of the average calculation?
I want an average of the time (in days) between two milestones for many different people (one person per row), but I want the formula to ignore that row if there isn't a date in BOTH date cells, since it throws off the average in a major way.
Example "TABLE_1"
EE Name | MILESTONE 1 | MILESTONE 2 |
Dave | 4/12/22 | 5/12/22 |
Steve | 6/1/22 | 6/5/22 |
Bill | 7/22/22 | 7/26/22 |
Frank | 8/1/22 |
Current Formula =SUMPRODUCT(TABLE_1[MILESTONE 2]-TABLE_1[MILESTONE 1])/COUNT(TABLE_1[MILESTONE 2])&" Days"
As long as both milestone 1 and 2 are populated, the formula works great, but if milestone 1 is populated and milestone 2 isn't, then it throws the whole thing off. How would I write a formula where if row 5 as above has a blank, then neither columns 2 or 3 for that row are part of the average calculation?
Last edited: