Use MASS package inside Exploratory.io

Hi, I was wondering how can I use MASS package inside Exploratory.io? I’ve already load the MASS package inside my project, when I try to run the same R code that I used inside R Studio, it gave me this error :

“Error in lqs.default(structure(c(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, : ‘x’ and ‘y’ must have the same number of rows”

In exploratory.io : MASS::rlm(price~lot_area, data=house_uk, psi = psi.bisquare, method = c(“MM”))
In RStudio : house_robust <- rlm(price~lot_area, data=house_uk, psi = psi.bisquare, method = c(“MM”))

I can run the code inside R studio with no issue. I’m using ‘rlm’ function (page 127 in MASS cran). Thank you!

You might want to take a look at this tutorial on how to run SVM.

https://docs.exploratory.io/user-defined-model-function.html

Basically, you want to create a custom R script and make sure to have it always return a data frame.

-Kan