dplyr'sdplyr
's left_join keeps all of the rows on the left (a) and joins b, adding all the columns from b. This way, none of the information from the data frame that contains the information about the polygons is changed. That might solve this problem.
The command would be:
library(dplyr)
foo <- left_join(mydf, bar)