Re: [Rpy] rpy2.predict

2012-04-02 Thread Elizabeth Tseng
I see. I changed the code to the following and it worked! import rpy2 import rpy2.robjects as robj robj.packages.importr("kernlab") robj.r.load("MPDR.training_size2000.RData") model = robj.globalenv["model"] outcome = robj.r.predict(model) Many thanks! --Elizabeth On Sun, Apr 1, 2012 at 10:59 PM

Re: [Rpy] rpy2.predict

2012-04-01 Thread Laurent Gautier
On 2012-04-02 03:07, Elizabeth Tseng wrote: Hi, I've just started using rpy/rpy2. I have a SVM model trained using the kernlab package. I stored the model in a R file called "MPDR.training_size2000.RData" (so if I call 'load' in R, the object 'model' is the trained model). I'm trying to loa

[Rpy] rpy2.predict

2012-04-01 Thread Elizabeth Tseng
Hi, I've just started using rpy/rpy2. I have a SVM model trained using the kernlab package. I stored the model in a R file called "MPDR.training_size2000.RData" (so if I call 'load' in R, the object 'model' is the trained model). I'm trying to load the model through rpy2, then run predict() on it