Error in R long vectors not supported yet

541 Views Asked by At

I am using CentOS 7 Linux compute cluster, with 130 GB RAM. I am trying to use the SVM function from the e1071 R package. My matrix dimension is rows = 350 and columns = 54250.

R script Code (file_testR.R)

matris=matrix(rnorm(100),350,54251)
matris <- as.data.frame(matris)
matris$new_variable <- 0
matris$new_variable[1:175] <- "yes"
matris$new_variable[176:350] <- "no"
require(e1071)
svmfit_test <- svm(as.factor(matris$new_variable)~., data = matris, kernel = "linear", cross=10)

Bash code

Rscript --max-ppsize=500000 file_testR.R

I am getting this below error:

Error in model.matrix.default(Terms, m) : 
  long vectors not supported yet: ../../src/include/Rinlinedfuns.h:522
Calls: svm ... svm.formula -> model.matrix -> model.matrix.default

I would appreciate it if anybody could help me to understand this issue.

0

There are 0 best solutions below