I have two data frames with some overlapping variables and some not. Each variable has an attribute (frequency of variable) and I need to combine the two into one dataframe where the result is two columns of attributes, one corresponding to the first dataframe, and the second corresponding to the first data frame, and the union of all the variables are represented.
dataframe 1:
var frequency
a 3
b 2
d 5
dataframe 2:
var frequency
a 2
b 3
c 3
Resulting dataframe:
var frequency1 frequency2
a 3 2
b 2 3
c 0 3
d 5 0
Thanks for your help.