title: How to look up a value by matching information and create a new variable with same data in r?
body: <p>I have a dataframe below.</p>
  <p><a href="https://i.stack.imgur.com/otHL1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/otHL1.png" alt="enter image description here" /></a></p>
  <p>I am trying to create a new variable (<strong>oldType</strong>) by matching information , comparing last month's <strong>ID</strong>, <strong>alpha_CLASS</strong>, <strong>num_Class</strong>, and <strong>TYPE</strong>.</p>
  <p><a href="https://i.stack.imgur.com/1Vame.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/1Vame.png" alt="enter image description here" /></a></p>
  <p>Is it possible to implement this in r?</p>
  <p>Your input would be really appreciated.</p>