I am experiencing an error in R that says:
> Error: protect(): protection stack overflow
I have learned through googling that I need to increase:
> --max-ppsize
R-manual:Memory
This can only be set when starting R so I write the following in the command prompt:
C:\Program Files\RStudio\bin\rstudio.exe --max-ppsize=5000000
The error still occurs. I am running a 1500R x 26000C dataset.
How do I solve this problem?
Edit:
The problem occurs in a standard SVM() function, where I pass a dataset of the size 600R x 26.000C. It does not happen when the dataset is 600R x 12.000C.
> model <- svm(TARGET ~ ., data = ds, type = "C-classification", kernel "linear", scale = TRUE, cost = c, cross = k)
I found a similar problem and that the actual issue was related to expansion of formulas into a model matrix. If you can get the data into that format without using formulas and then use the overload in the svm command (like many other models) that takes an X and y value instead, your probably may go away like mine did.
My way to fix a problem similar to yours:
Do the coding... NO original Error for me!!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With