title: combining tables with some overlapping row names in R
body: <p>While I am sure this has been asked before, reading through replies to similar threads still hasn't helped me make this work...</p>
  
  <p>I have two tables, A and B. <em>(This example is simplified, but it's ultimately what I would like to be able to do with two tables that are 16000rows x 390columns and 15800rows x 270columns)</em></p>
  
  <p>Row names for A are (Arts, History, Maths, etc..., <strong>French, HomeEc</strong>) while row names for B are (Arts, History, Maths, etc..., <strong>Spanish, Photography</strong>). </p>
  
  <p>Column names for each table are 20 different students (A: Student1-Student20; B: Student21-Student40)</p>
  
  <p>Values in each table are test scores.</p>
  
  <p>How do I combine these two tables in R, such that the final table contains row names (Arts, History, Maths, etc..., French, HomeEc, Spanish, Photography) without duplications, and the values in each column are the corresponding test score of Student1-40 (or 0, when that row was not present in the original table)?</p>
  
  <p>Thank you so much!</p>