Skip to content
Prev 361848 / 398506 Next

Merging Issue

Don't use HTML on sending email- messes up the data.

What do you mean that you get lots of duplicates?  If you have duplicated
entries in df2 this will lead to dups because of the way merge works (here
is the help file):

 If there is more than one match, all possible matches contribute
     one row each.  For the precise meaning of ?match?, see ?match?.

So you need to define the problem that you want to solve in going the
merge.  Here is what happens in your data if I duplicate some entries in
df2; is this what you are seeing:
deps Subject      dates loc grp
1     A       2 2011-01-01  CA  DE
2     A       2 2011-01-01  yy  xx
3     A       3 2011-01-06  CA  DE
4     A       3 2011-01-06  yy  xx
5     A       5 2011-01-11  CA  DE
6     A       5 2011-01-11  yy  xx
7     A       5 2011-01-09  CA  DE
8     A       5 2011-01-09  yy  xx
9     B       2 2011-01-02  NY  OC
10    C       3 2011-01-04  CA  DE
11    C       2 2011-01-03  CA  DE
12    D       5 2011-01-12  NY  OT
13    D       3 2011-01-05  NY  OT
14    F       5 2011-01-10  WA  DE
15    F       4 2011-01-07  WA  DE
16    G       4 2011-01-08  WA  OC



Jim Holtman
Data Munger Guru

What is the problem that you are trying to solve?
Tell me what you want to do, not how you want to do it.

On Fri, Jun 17, 2016 at 8:33 PM, Farnoosh Sheikhi via R-help <
r-help at r-project.org> wrote: