Calculate an average not including today
I'm trying to write a formula that calculates the percentage of appointments held by our team. I have a Date Appt Set and a Yes or No for Appt Held. What I want to do is not include appointments scheduled for today (even though they are in the sheet), I want a rolling 30-day average and I don't want to include weekends in that 30 day average.
How can I do that in a single Summary formula?
Thanks
Best Answers
-
Hi @Andrea Westrich ,
Try this:
=IFERROR(countifs([date appt set]:[date appt set],>TODAY(-31),[date appt set]:[date appt set],<TODAY(),[Appt Held]:[Appt Held],"Yes")/countifs([date appt set]:[date appt set],>TODAY(-31),[date appt set]:[date appt set],<TODAY()),"")
Let me know if it works for you.
Best,
Heather
-
@Andrea Westrich Actually, I just did a test, and 41 is the magic number. No matter what 41-day date range you choose in the year, the net workdays is always 30. So, try this:
=IFERROR(countifs([date appt set]:[date appt set],>TODAY(-41),[date appt set]:[date appt set],<TODAY(),[Appt Held]:[Appt Held],"Yes")/countifs([date appt set]:[date appt set],>TODAY(-41),[date appt set]:[date appt set],<TODAY()),"")
Answers
-
Hi @Andrea Westrich ,
Try this:
=IFERROR(countifs([date appt set]:[date appt set],>TODAY(-31),[date appt set]:[date appt set],<TODAY(),[Appt Held]:[Appt Held],"Yes")/countifs([date appt set]:[date appt set],>TODAY(-31),[date appt set]:[date appt set],<TODAY()),"")
Let me know if it works for you.
Best,
Heather
-
Thank you! The formula does work. Can you tell me how this eliminates weekends?
I appreciate your help!
-
@Andrea Westrich Well, it doesn't really. I honestly skipped that part!
A follow-up question, though: do you have any appointments scheduled on weekends? Or, do you just want it to be a rolling 30 work days (so, approximately 38 days, which includes 4 weekends)? We can tweak the formula a bit.
-
@Heather D, we do book appts on the weekend, but they are reported in totality on Monday. So, I want to show and average 30 working days. To do this I should change the formula to 38 (8 days a month)?
-
@Andrea Westrich Actually, I just did a test, and 41 is the magic number. No matter what 41-day date range you choose in the year, the net workdays is always 30. So, try this:
=IFERROR(countifs([date appt set]:[date appt set],>TODAY(-41),[date appt set]:[date appt set],<TODAY(),[Appt Held]:[Appt Held],"Yes")/countifs([date appt set]:[date appt set],>TODAY(-41),[date appt set]:[date appt set],<TODAY()),"")
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 139 Industry Talk
- 471 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!