title: R caret regression
body: <p>Trying to use R <code>caret</code> to train a model using <code>lm</code> linear regression:</p>
  
  <p>Code is as per below:</p>
  
  <pre><code>modelLm &lt;- train(x=X_train,y=Y_train, method="lm", na.action = na.omit, trControl=control)
  </code></pre>
  
  <p>But get the error: </p>
  
  <pre><code>Error in quantile.default(y, probs = seq(0, 1, length = cuts)) : 
              missing values and NaN's not allowed if 'na.rm' is FALSE 
  </code></pre>
  
  <p>Isn't <code>na.action = na.omit</code> supposed to ignore the missing values?</p>