Hello there Pardon my ignorance but, I have two data files with different series of dates and x and y values. There are common dates in both files. For example >datafile1 date1 xval 31/12/1982 20 1/01/1983 30 2/01/1983 40 3/01/1983 50 4/01/1983 60 5/01/1983 70 ... 01/01/2010 77 ... 31/12/1012 99
>datafile2 date2 yval 3/01/1983 0.4 4/01/1983 0.5 5/01/1983 0.6 .. 01/01/2010 88 All I want is a file/object that merges the two files with data for common dates to look like this. date yval xval 3/01/1983 0.4 50 4/01/1983 0.5 60 5/01/1983 0.6 70 .. 01/01/2010 88 77 I tried ' merge' and ' join' commands but somehow I have not been able to get that. Any help will be appreciated. Thank you. Best regards Santosh Aryal CSIRO Land and Water GPO Box 1666, Canberra ACT 2601 Ph: 02 6246 5963 Email: santosh.ar...@csiro.au<mailto:santosh.ar...@csiro.au> [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.