title: Error: One or more factor levels in the outcome has no data: '0'
body: <p>I am trying to perform a CART with caret package but I have this error continously.</p>
  
  <pre><code>train_control&lt;-trainControl(method="LOOCV")
  model&lt;-train(clase ~ ., data=mydata, trControl=train_control, method="rpart")
  </code></pre>
  
  <blockquote>
    <p>Error: One or more factor levels in the outcome has no data: '0'</p>
  </blockquote>
  
  <p>This is gene expression data so there are a lot of "0" y in my data but I want to preserve it because this is information. </p>