test<-left_join(vol,pri,by=c('sku','year','month'))
test<-merge(x = vol, y = pri, by =c("sku","year","month"),all.x=TRUE)
I tried these two. It returns a data frame with pri's columns full of NAs. I made sure that the columns in 'by' parameter are of the same type in pri and vol Also checked a few cases within pri and vol to make sure that there are at least a few matches Could I have made any mistake? Or is there something else i can try?
vol looks something like: sku year month volume
pri looks like: sku year month size pack price
I want test to be: sku year month volume price size pack
in any order. I am getting the right structure out of the functions but the data is just NAs with no matches.