[Rd] joining columns as in a relational database

Marc Schwartz MSchwartz at medanalytics.com
Wed Jun 25 04:57:32 MEST 2003


On Tue, 2003-06-24 at 21:46, Douglas Bates wrote:
> Marc Schwartz <MSchwartz at medanalytics.com> writes:
> 
> > On Tue, 2003-06-24 at 18:07, Douglas Bates wrote:
> 
> > > Several questions:
> > > 
> > >  - Am I duplicating existing functionality?
> ...
> 
> > Prof. Bates,
> > 
> > Perhaps I am not seeing all of the details but a quick (perhaps too
> > quick) review would suggest that merge(), which is in base, would at
> > least be a parallel function.
> 
> No, you are seeing better than I.  I had not thought to look up merge
> - I only thought of join.  I can use merge.  The answer to my first
> question is that I am duplicating functionality.
> 
> It was an interesting exercise.  Thanks for pointing out merge.


Glad to be of help.

What is interesting is that merge() does not show up if one uses
help.search("join"). The function description is:

"Merge two data frames by common columns or row names, or do other
versions of database ``join'' operations."

It would seem to be worthwhile to add 'join' as a \keyword and \alias
for merge(). 

Also, since cbind() is listed in the merge() "See Also" list, it would
seem logical to add merge() to "See Also" for cbind().

Both adjustments would probably make it easier to find merge() and save
time.

Regards,

Marc



More information about the R-devel mailing list