[R] Writing the output of a regression object to a file

Hanlie Pretorius hanlie.pretorius at gmail.com
Tue Jul 19 16:58:58 CEST 2011


I'm using R 2.12.0 on Windows XP.

I've used the e1071 package to tune a Support Vector Regression object
and I've created the SVR object:

> epsilon.svr <- svm(C8R004 ~.,data = rain_flow.train, scale = T, type = "eps-regression",
+ kernel = "radial", cost = 0.9, epsilon=0.55,tolerance=0.001,
shrinking=T, gamma=0.18,fitted=T)
> esvr.pred <- predict(epsilon.svr,newdata = rain_flow.test)

I would like to export the esvr.pred object to a file so that I can
draw a graph of it against my original data in other software that I'm

I've tried the write.svm command, but that outputs the scaled data
instead of something that I can directly compare to my original data.

Does anyone know of an easy way to get the result such a format?

Alternatively, how can I use the scale values to generate such a format?


More information about the R-help mailing list