Skip to content
xlsoffice. All Rights Reserved
  • Home
  • Excel For Beginners
  • Excel Intermediate
  • Advanced Excel For Experts

Lookup and Reference Examples

  • Find closest match in Excel
  • How to get last row in text data in Excel
  • Two-way lookup with VLOOKUP in Excel
  • How to use Excel ROWS Function
  • How to get address of first cell in range in Excel

Data Analysis Examples

  • How to conditionally sum numeric data in an Excel table using SUMIFS
  • How To Perform and Interpret Regression Analysis in Excel
  • Get column index in Excel Table
  • Working With Tables in Excel
  • Randomize/ Shuffle List in Excel

Data Validation Examples

  • Data validation must not exist in list
  • Excel Data validation don’t exceed total
  • How To Create Drop-down List in Excel
  • Excel Data validation date in next 30 days
  • Excel Data validation require unique number

Two-way summary count with COUNTIFS in Excel

by

This tutorial shows how to work Two-way summary count with COUNTIFS in Excel using the example below;

Formula

=COUNTIFS(range1,critera1,range2,critera2)

Explanation

To build a two-way summary count (i.e. summarizing by rows and columns) you can use the COUNTIFS function.

In the example shown, the formula in G5 is:

=COUNTIFS(dept,$F5,class,G$4)

How this formula works

The COUNTIFS function is designed to count things based on more than one criteria. In this case, the trick is to build a summary table first that contains one set of criteria in the left-most column, and a second set of criteria as column headings.

Worked Example:   Count cells between two numbers in Excel

Then, inside COUNTIFS function, range1 is the named range “dept” (C5:C11) and the criteria comes from column F, input as the mixed reference $F5 (to lock the column). Range2 is the named range “class” (D5:D11) and the criteria comes from row 4, input as the mixed reference G$4 (to lock the row):

 =COUNTIFS(dept,$F5,class,G$4)

When this formula is copied through the table the mixed references change so that COUNTIFS will generate a count as the intersection of each “pair” of intersecting criteria.

Post navigation

Previous Post:

SUMPRODUCT count multiple OR criteria in Excel

Next Post:

Summary count by month with COUNTIFS in Excel

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Learn Basic Excel

Ribbon
Workbook
Worksheets
Format Cells
Find & Select
Sort & Filter
Templates
Print
Share
Protect
Keyboard Shortcuts

Categories

  • Charts
  • Data Analysis
  • Data Validation
  • Excel Functions
    • Cube Functions
    • Database Functions
    • Date and Time Functions
    • Engineering Functions
    • Financial Functions
    • Information Functions
    • Logical Functions
    • Lookup and Reference Functions
    • Math and Trig Functions
    • Statistical Functions
    • Text Functions
    • Web Functions
  • Excel VBA
  • Excel Video Tutorials
  • Formatting
  • Grouping
  • Others
  • How to strip html from text or numbers in Excel
  • How to Check If A Cell Contains Specific Text in Excel
  • Get last name from name with comma — Manipulating NAMES in Excel
  • MID, MIDB functions: Description, Usage, Syntax, Examples and Explanation
  • UNICODE function: Description, Usage, Syntax, Examples and Explanation
  • How to calculate nth day of year in Excel
  • How to calculate future date say 6 months ahead in Excel
  • Get first Monday before any date in Excel
  • How to calculate next day of week in Excel
  • How to determine year is a leap year in Excel
  • Calculate loan interest in given year in Excel
  • How to calculate Net Present Value (NPV) in Excel
  • Future value vs. Present value examples in Excel
  • TBILLEQ function: Description, Usage, Syntax, Examples and Explanation
  • Example of payment for annuity in Excel
© 2022 xlsoffice . All Right Reserved. | Teal Smiles