I have one data frame df1 which contains the mean of heart rate (HR_mean) and rr (RR_mean) of one person taken from the experiment session 1:
heart.rate rr HR_mean RR_mean
86 790 83.4 801.8
84 828 83.4 801.8
84 767 83.4 801.8
82 811 83.4 801.8
81 813 83.4 801.8
I have another data frame df2 with empty columns HR_mean and RR_mean:
Person Session HR_mean RR_mean
Person1 1
Person1 2
Person2 1
Person2 2
Person3 1
I want to copy the values of HR_mean and RR_mean in df1 to the HR_mean and RR_mean columns in df2 like this:
df2:
Person Session HR_mean RR_mean
Person1 1 83.4 801.8
Person1 2
Person2 1
Person2 2
Person3 1