跳到主要内容

如何计算Google表格中某列的出现次数?

假设您在Google表格的A列中有一个名称列表,现在,您想要计算每个唯一名称出现的次数,如下所示。 在本教程中,我将在Google表格中讨论解决此工作的一些公式。

使用辅助公式计算Google工作表中某列中的出现次数

用公式计算Google工作表中某列中的出现次数


使用辅助公式计算Google工作表中某列中的出现次数

在这种方法中,您可以首先从列中提取所有唯一名称,然后根据唯一值对出现次数进行计数。

1。 请输入以下公式: =唯一(A2:A16) 放入要提取唯一名称的空白单元格,然后按 输入 键,所有唯一值都已列出,如以下屏幕截图所示:

备注:在上式中 A2:A16 是您要计数的列数据。

2。 然后继续输入以下公式: = COUNTIF(A2:A16,C2) 在第一个公式单元格旁边,按 输入 键以获取第一个结果,然后将填充手柄向下拖动到要计算唯一值出现次数的单元格,请参见屏幕截图:

备注:在上式中 A2:A16 是您要从中计算唯一名称的列数据,并且 C2 是您提取的第一个唯一值。


用公式计算Google工作表中某列中的出现次数

您还可以应用以下公式来获取结果。 请这样做:

请输入以下公式: = ArrayFormula(QUERY(A1:A16&{“”,“”},“选择Col1,count(Col2)其中Col1!=”按Col1标签count(Col2)'Count'”,1)分组) 放入要放入结果的空白单元格,然后按 输入 键,并立即显示计算结果,请参见屏幕截图:

备注:在上式中 A1:A16 是数据范围,其中包括要计数的列标题。


计算Microsoft Excel列中的出现次数:

Kutools for Excel高级组合行 实用程序可以帮助您计算一列中的出现次数,还可以基于另一列中的相同单元格来组合或求和相应的单元格值。

Kutools for Excel:具有300多个方便的Excel加载项,可以在30天内免费试用,没有任何限制。 立即下载并免费试用!

最佳办公生产力工具

🤖 Kutools 人工智能助手:基于以下内容彻底改变数据分析: 智能执行   |  生成代码  |  创建自定义公式  |  分析数据并生成图表  |  调用 Kutools 函数...
热门特色: 查找、突出显示或识别重复项   |  删除空白行   |  合并列或单元格而不丢失数据   |   不使用公式进行四舍五入 ...
超级查询: 多条件VLookup    多值VLookup  |   跨多个工作表的 VLookup   |   模糊查询 ....
高级下拉列表: 快速创建下拉列表   |  依赖下拉列表   |  多选下拉列表 ....
列管理器: 添加特定数量的列  |  移动列  |  切换隐藏列的可见性状态  |  比较范围和列 ...
特色功能: 网格焦点   |  设计图   |   大方程式酒吧    工作簿和工作表管理器   |  资源库 (自动文本)   |  日期选择器   |  合并工作表   |  加密/解密单元格    按列表发送电子邮件   |  超级筛选   |   特殊过滤器 (过滤粗体/斜体/删除线...)...
前 15 个工具集12 文本 工具 (添加文本, 删除字符,...)   |   50+ 图表 类型 (甘特图,...)   |   40+ 实用 公式 (根据生日计算年龄,...)   |   19 插入 工具 (插入二维码, 从路径插入图片,...)   |   12 转化 工具 (小写金额转大写, 货币兑换,...)   |   7 合并与拆分 工具 (高级组合行, 分裂细胞,...)   |   ... 和更多

使用 Kutools for Excel 增强您的 Excel 技能,体验前所未有的效率。 Kutools for Excel 提供了 300 多种高级功能来提高生产力并节省时间。  单击此处获取您最需要的功能...

产品描述


Office Tab 为 Office 带来选项卡式界面,让您的工作更加轻松

  • 在Word,Excel,PowerPoint中启用选项卡式编辑和阅读,发布者,Access,Visio和Project。
  • 在同一窗口的新选项卡中而不是在新窗口中打开并创建多个文档。
  • 每天将您的工作效率提高50%,并减少数百次鼠标单击!
Comments (14)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
可以限制规定内容出现的频次吗
This comment was minimized by the moderator on the site
Thanks!!! how do I count multiple columns?Ie column A, B,C,D all have names that needs to be counted
This comment was minimized by the moderator on the site
Thank you for this! Been trying to figure it out for hours!
This comment was minimized by the moderator on the site
Hi, I am trying to filter out some data from a sheet that is regularly updated. To simplify keeping track of the data I have a reporting section on the google sheet.The problem is that the data isn't organized in the most ideal way.

There are 2 columns that I want to use specific data from to create a filter, then with the leftover names I want to know how many unique names there are


Column 1 - Filter with A for one report field, B for the other report field (I will manually change this in the formula)

Column 2 - There are 9 Text entries possible. I want to only include 3 of them as a Filter

Column 3 - There are a couple of thousand entries(names), many are the same in multiple rows. With the data filtered using Column 1, and Column 2, I want to get a number for how many unique names are left after the data has been filtered.


I am not used to having this many things I am trying to filter the data from so any help would be hugely appreciated.


Have an excellent day
This comment was minimized by the moderator on the site
I have a google sheet with a lot of information but I am looking to filter it down into a report.

Column1 - Options are A, B (The is the first data to sort)
Column 2 - has 3 of the text string that I want my sum to include, but I want to leave out the others 5.
Column 3 - Names that I want to know how many unique names there are

What I am looking to figure out is the following

Option A, the sum to only include 3 text string that appears multiple times in a 2nd column, The total being how many unique names there are in Column 3

Hoping someone can help as this is a bit over my experience level
This comment was minimized by the moderator on the site
My count isn't grouping the names together.
i.e.
Column B says
Independence
Walnut St.
Parkway
Walnut St.
and instead of my " count " column saying Walnut St. 2 it says
Walnut St. 1
Walnut St. 1

How can I fix this ?
This comment was minimized by the moderator on the site
This is partly what I'm looking for.
Now my next issue is, how can I sort these so that I get them in desending order?
So it should be looking like this:
James 4
Nicol 3
Ruby 3
Lucy 2
Tom 2
John 1

Hope you can help with that as well
This comment was minimized by the moderator on the site
Hi,
If you want to sort the results in descending order, you just need to sort the data by the formula result column after getting the result.
Hope it can help you!
This comment was minimized by the moderator on the site
Whenever I try to sort, I get an error, is there a way I can fix that? I have the $A$1:$A$7, B1 as my formula - is there something in my formula I should edit?
This comment was minimized by the moderator on the site
VERY useful - thank you so much!
This comment was minimized by the moderator on the site
Thanks! Super useful!
This comment was minimized by the moderator on the site
When you drag the handle down to apply it to the rest of the values, it increments the search radius by 1. So if youre searching =COUNTIF(A1:A10,C1), when you drag the handle down, the second value will be =COUNTIF(A2:A11,C2).
This comment was minimized by the moderator on the site
This is SOOO helpful! This skips an entire step
This comment was minimized by the moderator on the site
You fix it this way
=COUNTIF($A$2:$A$11,C2)
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations