Excel Blog - Calculations on a Filtered List
Auto filter is a wonderful thing isn’t it? With a few clicks of the mouse little dropdowns appear letting you filter your data in a myriad different ways.
Hi, we are Happy
We are leading a movement to create happy, empowered and productive workplaces.
How can we help you and your people to find joy in at least 80% of your work?
But what if you want to find out the total or average of your filtered data? Unfortunately the SUM, AVERAGE, COUNT, COUNTA etc functions seem to let us down here.
Here’s my unfiltered data and the SUM function in action:
And here’s my filtered data:
Notice anything different? No? Exactly! We may want the SUM function to only sum the visible data but, as it was designed to do, it will sum ALL of the data, even the hidden rows.
So what’s the answer? The SUBTOTAL function!
The subtotal function can, if we ask it nicely, ignore any values hidden by the autofilter. It looks like this:
=SUBTOTAL(function_num,ref1,[ref2], . . . . ])
The function_num argument tells the subtotal function what sort of calculation you want it to do:
So here’s the same example as above using the subtotal function:
Why not sign up to our newsletter?
Sign up to our monthly newsletter, full of tips, tricks and news to help you to be happier and more productive at work.
Darren is one of Happy's Senior Trainers, able to train almost every IT course on our course programme. He worked for Happy for 12 years and has been an Associate Trainer since 2018.
Testimonials from happy Customers
Birgit Gaiser2 days ago
Energetic workshop facilitation, good materials provided. Good communication close to the workshop.
Jade Stapleton4 days ago
Thoughtful, well structured courses with responsive and expert trainers and a welcoming and inclusive atmosphere to learn in.
Gail Sullivan4 days ago
Course delivered in a very friendly way easy to follow. Picked up tips that would not have found without
Richard Nuthall4 days ago
Enjoyable, participatory and thought provoking. Thoroughly recommended.
Charlotte Bennett4 days ago
Had to chase to be rebooked on a new date after trainer didn't show up for our original session and some people did not receive joining instructions until the last minute
Joanne McGinnis4 days ago
Super facilitator. practical session with brilliant tips and techniques
Anita Borsberry4 days ago
The interaction was good due to smaller class size. The trainer explained all agenda items well. I would have liked course supporting documents earlier.
Angela McGough4 days ago
Very efficient, great paperwork and test guidance. Trainer was really helpful and patient with the learners and would hope to have her train our staff on the next level.
Keeley Kemp4 days ago
Brilliant friendly service
Mandeep Butt5 days ago
Anna Lister5 days ago
Really smooth from start to finish
Jude Goddard5 days ago
Friendly skilled and enthusiastic I enjoyed learning with them