title: R - remove anything after comma from column
body: <p>I'd like to strip this column so that it just shows last name - if there is a comma I'd like to remove the comma and anything after it. I have data column that is a mix of just last names and last, first. The data looks as follows:</p>
  
  <pre><code>Last Name  
  Sample, A  
  Tester  
  Wilfred, Nancy  
  Day, Bobby Jean  
  Morris  
  </code></pre>