title: Error in train from Caret
body: <p>I'm baffled.  I've used train before with no problem.  But now I'm repeatedly getting the "unused arguments" error.  </p>
  
  <pre><code>#Generate random data
  y &lt;- rnorm(100, mean=.5)
  x &lt;- rnorm(100)
  data &lt;- cbind(x, y)
  form &lt;- y ~ x
  
  fitControl &lt;- trainControl(## 10-fold CV
                         method = "cv",
                         number = 8)
  
  set.seed(825)
  lmFit1 &lt;- train(x, y, method = "lm", trControl = fitControl, na.action=na.omit)
  lmFit1 &lt;- train(form, data = data, method = "lm", trControl = fitControl, na.action=na.omit)
  </code></pre>
  
  <p>Since I am running a linear regression, I've specified this model both with x and y, and with form.  Both generate the same error.  </p>
  
  <pre><code>Error in train(form, method = "lm", trControl = fitControl, na.action = na.omit) : unused arguments (method = "lm", trControl = fitControl, na.action = na.omit)
  Error in train(x, y, method = "lm", trControl = fitControl, na.action = na.omit) : unused arguments (y, method = "lm", trControl = fitControl, na.action = na.omit)
  </code></pre>
  
  <p>In my actual data, I have many more predictors, and have played around with only including 1 or 2 predictors at a time, but all generate the same error.  Even the random data generates the error.  </p>
  
  <p>Any thoughts?  Help is much appreciated!  Thanks!</p>