```r
confusionMatrix(prediccion_2, vino_prueba_2[["tipo"]])
```

```
Confusion Matrix and Statistics

          Reference
Prediction  1  2  3
         1 14  0  0
         2  1 21  0
         3  0  0 17

Overall Statistics
                                          
               Accuracy : 0.9811          
                 95% CI : (0.8993, 0.9995)
    No Information Rate : 0.3962          
    P-Value [Acc > NIR] : < 2.2e-16       
                                          
                  Kappa : 0.9713          
                                          
 Mcnemar's Test P-Value : NA              

Statistics by Class:

                     Class: 1 Class: 2 Class: 3
Sensitivity            0.9333   1.0000   1.0000
Specificity            1.0000   0.9688   1.0000
Pos Pred Value         1.0000   0.9545   1.0000
Neg Pred Value         0.9744   1.0000   1.0000
Prevalence             0.2830   0.3962   0.3208
Detection Rate         0.2642   0.3962   0.3208
Detection Prevalence   0.2642   0.4151   0.3208
Balanced Accuracy      0.9667   0.9844   1.0000
```