当前在线人数13959
首页 - 分类讨论区 - 学术学科 - 统计版 - 同主题阅读文章

此篇文章共收到打赏
0

  • 10
  • 20
  • 50
  • 100
您目前伪币余额:0
未名交友
[更多]
[更多]
count unique values in file with 1 million rows
[版面:统计][首篇作者:light009] , 2014年04月12日16:11:22 ,130次阅读,0次回复
来APP回复,赚取更多伪币 关注本站公众号:
[分页:1 ]
light009
进入未名形象秀
我的博客
[回复] [回信给作者] [本篇全文] [本讨论区] [修改] [删除] [转寄] [转贴] [收藏] [举报] [ 1 ]

发信人: light009 (light009), 信区: Statistics
标  题: count unique values in file with 1 million rows
发信站: BBS 未名空间站 (Sat Apr 12 16:11:22 2014, 美东)

I need to count the unique values in one column in EXCEL 2010.

The worksheet has 1 million rows and 10 columns. All cell values are string
or numbers.

I used the solution at Count unique values in a column in Excel
=SUMPRODUCT((A2:A1000000<>"")/COUNTIF(A2:A100000,A2:A1000000&""))
But, it runs so long time that the EXCEL is almost frozen. And, it generates
25 processes in Win 7.

Are there more efficient ways to do it ?

Also, in the column, all values have for format of
  AX_Y

  here, A is a character, X is an integer, Y is an integer from 1 to 10.

  For example, A5389579_10
I need to cut off the part after (including) undersocre. for the example,
  A5389579
This is what I need to count as unique values in all cells in one column.
  For example, A5389579_10
               A1543848_6
               A5389579_8
here, the unique value has 2 after removing the part after underscore.

How to do it in EXCEL VBA and R (if no efficient solution for EXCEL) ?

Thanks !

--
※ 来源:·WWW 未名空间站 网址:mitbbs.com 移动:在应用商店搜索未名空间·[FROM: 205.]

 
[分页:1 ]
[快速返回] [ 进入统计讨论区] [返回顶部]
回复文章
标题:
内 容:

未名交友
将您的链接放在这儿

友情链接


 

Site Map - Contact Us - Terms and Conditions - Privacy Policy

版权所有,未名空间(mitbbs.com),since 1996