rr-caret

Error "Something is wrong; all the RMSE metric values are missing" using SBC from frbs package in Caret


I've been trying to fit a model using 'SBC' method from 'frbs' package in Caret for R. I've seen similar questions in SO for different packages and tried the solutions but they didn't seem to work in my case. I've provided a code snippet for reproducability using iris dataset.

library(caret)
data("iris")
grid<-expand.grid(r.a = c(0.5),
                                     eps.high = c(0.5),
                                     eps.low = c(0))

Fit <- train(Sepal.Length ~ Sepal.Width + Petal.Length + Petal.Width, data = iris,
                                 method = "SBC", 
                               #  trControl = fitControl,
                                 tuneGrid=grid,
                                 verbose = TRUE)

Fit$results

The error obtained is :

Something is wrong; all the RMSE metric values are missing:
      RMSE        Rsquared  
 Min.   : NA   Min.   : NA  
 1st Qu.: NA   1st Qu.: NA  
 Median : NA   Median : NA  
 Mean   :NaN   Mean   :NaN  
 3rd Qu.: NA   3rd Qu.: NA  
 Max.   : NA   Max.   : NA  
 NA's   :3     NA's   :3    
Error in train.default(x, y, weights = w, ...) : Stopping
In addition: There were 50 or more warnings (use warnings() to see the first 50)

I checked the warnings() and it shows "model fit failed for Resample17: r.a=0.5, eps.high=0.5, eps.low=0 Error in frbs.learn(data.train = structure(c(3.5, 3, 3.2, 3.1, 3.4, 3.4, : .....". I've even tried installing frbs package separately. Also i've ensured that the classes of the variables are not factors, even for my data.

My question is how can I fix this error and why does this error occur. Any help would be much appreciated.

Thanks in advance.


Solution

  • The issue has been resolved, thanks to Max Kuhn, author of Caret package. The link to the solution in Caret's github page is given here.