title: Add column to data frame based on values of another column in another row
body: <p>I was searching for an answer to my specific problem, but I didn't find a conclusion. I found this: <a href="https://stackoverflow.com/questions/26067161/add-column-to-data-frame-based-on-values-of-other-columns">Add column to Data Frame based on values of other columns</a> , but it was'nt exactly what I need in my specific case. 
  I'm really a beginner in R, so I hope maybe someone can help me or has a good hint for me.</p>
  
  <p>Here an example of what my data frame looks like:</p>
  
  <pre><code>ID     answer  1.partnerID  
  125    3       715        
  235    4       845         
  370    7       985          
  560    1       950          
  715    5       235          
  950    5       560          
  845    6       370          
  985    6       125          
  </code></pre>
  
  <p>I try to describe what I want to do on an example:
  In the first row is the data of the person with the ID 125. The first partner of this person is the person with ID 715. I want to create a new column, with the value of the answer of each person´s partner in it. It should look like this: </p>
  
  <pre><code>ID     answer  1.partnerID  1.partneranswer    
  125    3       715          5
  235    4       845          6
  370    7       985          6
  560    1       950          5
  715    5       235          4
  950    5       560          1
  845    6       370          7
  985    6       125          3
  </code></pre>
  
  <p>So R should take the value of the column 1.partnerID, which is in this case "715" and search for the row, where "715" is the value in the column ID (there are no IDs more than once).
  From this specific row R should take the value from the column answer (in this example that´s the "5") and put it into the new column "1.partneranswer", but in the row from person 125. 
  I hope someone can understand what I want to do ...</p>
  
  <p>My problem is that I can imagine how to write this for each row per hand, but I think there need to be an easiear way to do it for all rows in once? (especially because in my original data.frame  are 5 partners per person and there are more than one column from which the values should be transfered, so it would come to many hours work to write it for each single row per hand).</p>
  
  <p>I hope someone can help.
  Thank you!</p>