作者helixc (@_2;)
看板R_Language
标题Re: [问题] 找出重复的资料组
时间Fri Jul 3 09:18:19 2015
抱歉讲的不够详细...
假设我已经把birdtrip整合进来了,资料长这样:
>bird
date bird_id bird_name num place reporter birdtrip
1 2001-01-01 201 sp1 3 金门 John T0001
2 2001-01-01 202 sp2 2 金门 John T0001
3 2001-01-01 205 sp3 8 金门 John T0001
4 2001-01-01 3507 sp4 10 金门 John T0001
5 2001-01-01 4104 sp5 1 金门 John T0001
6 2001-01-01 4105 sp6 1 金门 John T0001
7 2011-11-05 4105 sp6 2 马祖 Mary T0002
8 2011-11-05 1003 sp7 5 马祖 Mary T0002
9 2013-05-21 999 sp8 10 绿岛 Terry T0003
10 2013-05-21 831 sp9 11 绿岛 Terry T0003
..
51 2001-01-01 201 sp1 3 金门 John T0001
52 2001-01-01 202 sp2 2 金门 John T0001
53 2001-01-01 205 sp3 8 金门 John T0001
54 2001-01-01 3507 sp4 10 金门 John T0001
55 2001-01-01 4104 sp5 1 金门 John T0001
56 2001-01-01 4105 sp6 1 金门 John T0001
bird[1:6,]和bird[51:66,]的资料是一模一样的,要怎麽抓出这种重复资料呢?
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 140.130.96.14
※ 文章网址: https://webptt.com/cn.aspx?n=bbs/R_Language/M.1435886301.A.C1E.html
1F:推 celestialgod: distinct(bird)就好, 你之前不该加变数的, 还有上 07/03 10:09
2F:推 celestialgod: 一篇的推文方法都适用 07/03 10:09
3F:→ helixc: 了解,看来是我想太多了... 07/03 10:40