title: how to form 1 column from an existing column defining 3 levels using R?
body: <p>My code</p>
  
  <pre><code>date$dmilk=ifelse(date$del&lt;=100,paste("1",date$dmilk),
      (date$del&gt;=100,paste("2",date$dmilk),
      (date$del&gt;=200,paste("3"date$dmilk),
      (date$del&gt;=300,paste("4",date$dmilk))
  </code></pre>
  
  <p>I would like to form the new <code>dmilk</code> column based on conditional constraints
  Can someone help me?</p>
  
  <hr>
  
  <pre><code>del dmilk
  21
  320
  362
  288
  81
  66
  267
  235
  229
  425
  383
  361
  197
  260
  106
  238
  74
  102
  148
  197
  329
  428
  </code></pre>