[R] best.svm

From: Stephen Choularton <mail_at_bymouth.com>
Date: Tue 24 May 2005 - 16:43:10 EST


Hi  

I am trying to fit an svm to predict speech recognition errors. I am using best.svm like this:  

svm.model = best.svm(data[1:3000,1:23],data[1:3000,24],tunecontrol = tune.control())  

I got this:  

> print(svm.model)
 

Call:
 best.svm(x = data[1:3000, 1:23], tunecontrol = tune.control(), data[1:3000, 24])  

Parameters:

   SVM-Type:  eps-regression 
 SVM-Kernel:  radial 
       cost:  1 
      gamma:  0.04347826 
    epsilon:  0.1 
 
 

Number of Support Vectors: 970  

But when I applied it:    

> pred = predict(svm.model, data[3001:4000,1:23])
> pred[pred > .5] = 1
> pred[pred <= .5] = 0
> t = table(pred,data[3001:4000,24])
> t
    

pred 0 1

   1 65 935
> classAgreement(t)

$diag
[1] 0.065  

$kappa
[1] 0  

$rand
[1] 0.8783283  

$crand
[1] 0  

It didn’t produce really good results.  

Will best.svm get me the best svm? Have I given it the wrong parameters?  

Any help most welcome.  

Stephen

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.

 

	[[alternative HTML version deleted]]

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Received on Tue May 24 16:52:00 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:32:01 EST