How to use Subtotal Formula in Excel – Excel Avon

Welcome to Excel Avon

What is Subtotal Formula

So in this video we are talking about Subtotal Formula. The Excel SUBTOTAL function  Returns a subtotal in a database or list, The SUBTOTAL function in Excel helps in analyzing the data provided. 

Formula

=SUBTOTAL(function_num, ref1, [ref2], ...)

Arguments

function_num –  A number that specifies which function to use in calculating subtotals within a list.

ref1 – All cell ranges to be included in the calculation

[ref2] – [optional] A named range or reference to subtotal.

How to Use Subtotal Formula 

You can download used excel file from here>>>

Formula For grand total(Visible Items)

So now we use the Subtotal formula in the example and let’s see how it will work. We have created some data in which everyone will use the total formula as the cell can see below, in it some fruits and vegetables will find their average and sum. 

Sub-total-formula-in-excel

So now we will apply the formula For grand total(Visible Items) : =SUBTOTAL(9,E8:E15)

Note : For addition, the Function number will use 9 For visible data & 109 for Ignore hidden.

Sub-total_formula_2

Now You Can See  grand total(visible Items) of fruits.

for-grand-totalvisible-item

Formula For Average Unit Price (Visible Items)

Now we will use the formula Average Unit Price (Visible Items) Function No. 1 For Visible Item We will use 101 for Hidden Number.

Average-unit-price

So now we will apply the formula For Average Unit Price (Visible Items) : =SUBTOTAL(1,D8:D12)

SUBTOTAL=function-values

If we remove the vegetable,

remove-some-filter.png

The grand total and average of the vegetable is removed.

You can download used excel file from here>>

Note 

  • In filtered lists, SUBTOTAL always ignores values in hidden rows, regardless of function_num.
  • SUBTOTAL works with vertical data. In horizontal ranges, values in hidden columns are always included.
  • Blank cells and cells containing non-numeric values are ignored by subtotal function during the calculation

Now you can try change lookup image value. So I hope you have understood this formula and for more information you can follow us on Twitter, Instagram, LinkedIn and YouTube as well.

You can also see well explained video here

You can also learn SUM Formula

 

Leave a Reply