I have looked at the various threads and sadly the answers provided are not working. I am merging two files. Both files have common column names. I want the two data sets to merge for the same time point, however when I use the command s3<-merge(s1,s2,all=TRUE)
, it gives me a file as follows:
I would like the duplicate time points to be removed.
If I use s3<-merge(s1,s2,all.x=TRUE)
, then none of the data from s2 gets merged.
When reading the data file I am using s2<-read.csv('X.csv',stringsAsFactors=FALSE)
.
I don't know where I am going wrong.