计算通过逗号分开的单词并向他们展示

发布于 2025-01-24 19:45:21 字数 408 浏览 1 评论 0原文

我尝试分开,计数,更扁平等等,但我会遇到错误。

我有一个位置列表和由逗号分隔的分组位置。例如:

A1 - Europe, south Europe, Africa
A2 - United stages, East Europe, south Europe
A4- blank
A5 - Africa, United stages 
And so on.

我想有一个计数器,可以告诉我这些国家出现了多少次,例如:

Europe 1
United stages 2
Africa 2
Etc

此外,它必须忽略空白细胞,因为我做过的大多数尝试都将它们视为错误,并使我的百分比弄乱了。

理想情况下,这将显示他们最大至最小的数字,但这是我在这里最不担心的。

I've tried splitting, counts, flatten and much more but I get errors.

I have a list of locations and grouped locations separated by comma. For example:

A1 - Europe, south Europe, Africa
A2 - United stages, East Europe, south Europe
A4- blank
A5 - Africa, United stages 
And so on.

I want to have a counter that will tell me how many times the countries appear, like this:

Europe 1
United stages 2
Africa 2
Etc

Also, it has to ignore blank cells because most successful try I've done counts them as errors and messes up my percentages.

Ideally this would show them up largest to smallest number, but this is the least of my worry here.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

像极了他 2025-01-31 19:45:21

使用:

=INDEX(QUERY(TRIM(FLATTEN(IFERROR(SPLIT(A1:A; ",")))); 
 "select Col1,count(Col1) 
  where Col1 is not null 
  group by Col1 
  order by count(Col1) desc 
  label count(Col1)''"))

use:

=INDEX(QUERY(TRIM(FLATTEN(IFERROR(SPLIT(A1:A; ",")))); 
 "select Col1,count(Col1) 
  where Col1 is not null 
  group by Col1 
  order by count(Col1) desc 
  label count(Col1)''"))

enter image description here

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文