Displaying 1 result from an estimated 1 matches for "hogtest".
Did you mean:
cogtest
2009 Nov 17
2
SVM Param Tuning with using SNOW package
...values of cost1, I guess the first 5, but not for the
last 5.
Please, can anyone help me! :-((
Here is the code:
data <- data.frame(Y=I(Y),X=I(X))
data.X<-data$X
data.Y<-data$Y
NR=10
cost1=seq(0.5,30, length=NR)
sv.lin<- function(cl,c) {
for (i in 1:NR) {
ind=sample(1:414,276)
hogTest<- data.frame(Y=I(data.Y[-ind]),X=I(data.X[-ind,]))
hogTrain<- data.frame(Y=I(data.Y[ind]),X=I(data.X[ind,]))
svm.lin <- svm(hogTrain$X,hogTrain$Y, kernel="linear",cost=c[i],
cross=5)
results.lin <- predict(svm.lin, hogTest$X)
e.test.lin <- sqrt(sum((results....