How to use the Count Function in Excel (easily)
79
How Do I Love Thee Excel? Let Me Count the Ways
Now that I nearly caused you to vomit with my corny subtitle (Elizabeth Barrett Browning is rolling over in her grave), let’s become acquainted with how to use the Count function in Excel.
In working with a large spreadsheet, if you needed to count the number of cells that contained a particular type of data, you could employ the appropriately named Count function. There are other ways to count data in Excel but utilizing the Count function is perhaps the most efficient method.
How This Tutorial is Organized
As I believe in keeping things simple, we’ll utilize a one column spreadsheet to demonstrate four variations of the Excel Count function. We’ll be using Excel 2003 in this tutorial.
In our first example, we’ll use the Count function to tally the number of cells that contain a number (any number). Next, we’ll apply the CountIf function to identify the number of cells that contain a specific “number”, “value” or “character.” In our third example, we’ll make use of the CountBlank function to count the number of blank cells. Finally, we’ll utilize CountA to count the number of non-blank cells.
Why Functions are Important– A comic by stld52
Using the Count Function
In the example below, the Count function is used in cell A:11 to tally the number of cells that contain a number. The total number is 7 in this case. A review of the actual function is provided after the example.
Function Explanation:
Syntax: Count(value1,value2,...)
The actual function that was entered in cell A:11 is :
=Count(A2:A10)
In this case, because we counted the numbers in Column A
only (value1), there was no need to provide a second value (value2). We merely needed
to enter the first value, which is A2:A10.
If we were also counting numbers in Column B (value2), we would have
entered the following:
=Count(A2:A10,B2:B10)
Using the CountIF Function
In our next example below, the CountIF function is used in cell A:11 to find out how many times the name George appears in Column A. The total number is 3 in this case. A review of the actual function is provided after the example.
Function Explanation:
Syntax: CountIF(range, criteria)
The actual function that was entered in cell A:11 is:
=CountIF(A2:A10,"George")
In this case, the range is once again A2:A10. The criteria is the name “George” in quotation marks. If the criteria had been the name “Bryan”, the number 1 would have displayed in cell A:11. Had the criteria been a number, we would have omitted the quotation marks in the actual function.
Using the CountBlank Function
In the third example below, the CountBlank function is used in cell A:11 to find out how many blank cells are listed in Column A. The total number is 4 in this case. A review of the actual function is provided after the example.
Function Explanation:
Syntax: CountBlank(range)
The actual function that was entered in cell A:11 is:
=CountBlank(A2:A10)
The range is A2:A10. In using CountBlank, cells with formulas that return no value or text are also counted. Cells with zero values are not counted.
Using the CountA Function
In our finally example below, the CountA function is used in cell A:11 to count the number of non-blank cells in Column A. The total number is 6 in this case. A review of the actual function is provided after the example.
Syntax: CountA(value1, value2,…)
The actual function that was entered in cell A:11 is:
=CountA(A2:A10)
In this final example, because we're counting non-blank cells in Column A only (value1), there was no need to provide a second value (value2). We merely needed to enter the first value, which is A2:A10. If we were also counting non-blank cells in Column B (value2), we would have entered the following:
=CountA(A2:A10,B2:B10)
Well done, you’re now equipped with a solid understanding of how to use the Count function in Excel. I welcome your questions or comments. Thanks!
PrintShare it! — Rate it: up down flag this hub









