Or if you need it to be fast, try data.table. X[Y] is a join when X and Y
are both data.tables. X[Y] is a left join, Y[X] is a right join. 'nomatch'
controls the inner/outer join i.e. what happens for unmatched rows. This
is much faster than merge().
Gabor Grothendieck
Hi,
With two data sets, one complete and another one partial, I would like to
merge them and keep the unmatched lines. The problem is that merge() dosen't
keep the unmatched lines. Is there another function that I could use to
merge the data frames.
Example:
completedf -
On Jun 10, 2009, at 8:56 AM, Etienne B. Racine wrote:
Hi,
With two data sets, one complete and another one partial, I would
like to
merge them and keep the unmatched lines. The problem is that merge()
dosen't
keep the unmatched lines. Is there another function that I could use
to
Try:
merge(completedf, partdf, all.x = TRUE)
or
library(sqldf) # see http://sqldf.googlecode.com
sqldf(select * from completedf left join partdf using(beta, alpha))
On Wed, Jun 10, 2009 at 9:56 AM, Etienne B. Racineetienn...@gmail.com wrote:
Hi,
With two data sets, one complete and
4 matches
Mail list logo