Re: [R] merging two data sets with no column header

From: Henrique Dallazuanna <wwwhsd_at_gmail.com>
Date: Wed, 04 Jun 2008 18:16:44 -0300

Perhaps something about like this:

 merge(vv[-c(which(duplicated(vv))-1, which(duplicated(vv))),], vv2, by=1)

On Wed, Jun 4, 2008 at 3:08 PM, kayj <kjaja27_at_yahoo.com> wrote:

>
>
>
> Thanks a lot for your help, I appreciate it.
>
>
>
>
> David Winsemius wrote:
> >
> > Thanks for your reply.
> >
> > In your last step If I create a duplicate ( two similar records )
> > # create a duplicate
> > vv[8,1] <- 7
> > vv[8,2]<-'g'
> >
> > and then I merge vv with vv2 ,both duplicates are merged. Is there a way
> > to tell R to merge only the unique records.
> >
> > ------
> >
> > I don't think merge will do what you are asking. Suspect you would need
> to
> > do it either before the merge or after. I tried using the Extract
> operator
> > on a merged dataset, but only succeeded in omitting the duplicated items,
> > not both instances.
> >
> > --
> > David Winsemius
> >
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/merging-two-data-sets-with-no-column-header-tp17613296p17652963.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

-- 
Henrique Dallazuanna
Curitiba-Paraná-Brasil
25° 25' 40" S 49° 16' 22" O

	[[alternative HTML version deleted]]


______________________________________________ R-help_at_r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Received on Wed 04 Jun 2008 - 21:50:46 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 04 Jun 2008 - 22:30:45 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive