Displaying 20 results from an estimated 7000 matches similar to: "svm code, what is wrong here?"
2006 Dec 07
1
svm plot question
I run the following code, all other is ok,
but plot(m.svm,p5.new,As~Cur) is not ok
Anyone know why?
install.packages("e1071")
library(e1071)
library(MASS)
p5 <- read.csv("http://www.public.iastate.edu/~aiminy/data/p_5_2.csv")
p5.new<-subset(p5,select=-Ms)
p5.new$Y<-factor(p5.new$Y)
levels(p5.new$Y) <- list(Out=c(1), In=c(0))
attach(p5.new)
2006 Dec 08
1
please help me for svm plot question
I run the following code, all other is ok,
but plot(m.svm,p5.new,As~Cur) is not ok
Anyone know why?
install.packages("e1071")
library(e1071)
library(MASS)
p5 <- read.csv("http://www.public.iastate.edu/~aiminy/data/p_5_2.csv")
p5.new<-subset(p5,select=-Ms)
p5.new$Y<-factor(p5.new$Y)
levels(p5.new$Y) <- list(Out=c(1), In=c(0))
attach(p5.new)
2006 Nov 26
1
plot p(Y=1) vs as
I am trying to fit a logistic regression model for this data set.
Firstly, I want to plot P(Y=1) vs As and P(Y=1) vs Aa.
Does any body know how to do these in R.
Thanks,
Aimin
> p5 <- read.csv("http://www.public.iastate.edu/~aiminy/data/p_5_2.csv")
> str(p5)
'data.frame': 1030 obs. of 6 variables:
$ P : Factor w/ 5 levels "821p","8ABP",..: 1
2009 May 11
1
Problems to run SVM regression with e1071
Hi R users,
I'm trying to run a SVM - regression using e1071 package but the function svm() all the time apply a classification method rather than a regression.
svm.m1 <- svm(st ~ ., data = train, cost = 1000, gamma = 1e-03)
Parameters:
SVM-Type: C-classification
SVM-Kernel: radial
cost: 1000
gamma: 0.001
Number of Support Vectors: 209
2011 Feb 23
0
svm(e1071) and scaling of weights
I expected, that I will get the same prediction, if I multiply the
weights for all classes with a constant factor, but I got different
results. Please look for the following code.
> library(e1071)
> data(Glass, package = "mlbench")
> index <- 1:nrow(Glass)
> testindex <- sample(index, trunc(length(index)/5))
> testset <- Glass[testindex, ]
> trainset <-
2017 Sep 02
0
problem in testing data with e1071 package (SVM Multiclass)
Hello all,
this is the first time I'm using R and e1071 package and SVM multiclass
(and I'm not a statistician)! I'm very confused, then. The goal is: I
have a sentence with sunny; it will be classified as "yes" sentence; I
have a sentence with cloud, it will be classified as "maybe"; I have a
sentence with rainy il will be classified as "no".
The
2013 Jan 08
0
bagging SVM Ensemble
Dear Sir,
I got a problem with my program. I would like to classify my data using
bagging support vector machine ensemble. I split my data into training data
and test data. For a given data sets TR(X), K replicated training data sets
are first randomly generated by bootstrapping technique with replacement.
Next, Support Vector Mechine (SVM) is applied for each bootstrap data sets.
Finally, the
2011 Feb 18
1
segfault during example(svm)
If do:
> library("e1071")
> example(svm)
I get:
svm> data(iris)
svm> attach(iris)
svm> ## classification mode
svm> # default with factor response:
svm> model <- svm(Species ~ ., data = iris)
svm> # alternatively the traditional interface:
svm> x <- subset(iris, select = -Species)
svm> y <- Species
svm> model <- svm(x, y)
svm>
2009 Feb 20
0
e1071 package for SVM
Dear all,
I got a code for e1071 package in R for SVM regression. I
have used *m$coefs* for extracting the coefficients but I am getting only
72 . How can I extract coefficients of the predictors set? Does it mean
that I will get only 72 as *Number of Support Vectors: 72. *
**
Thanks in advance
Code:
--------------
library(e1071)
> # create data
> x <- seq(0.1, 5,
2012 Aug 07
1
Interpreting predictions of svm
Hi, I have some difficulties in interpreting the prediction of a svm model
using the package e1071.
y1 is the variable I want to predict. It is of type factor and has got two
levels: "< 50%" and "> 50%".
z is the dataset.
> model <- svm(y1 ~ ., data = z,type="C-classification", cross=10)
> model
Call:
svm(formula = y1 ~ ., data = z, type =
2007 Oct 27
1
problems in cross validation of SVM in pakage "e1071"
Hi:
I am a newer in using R for data mining, and find the "e1071" pakage an excellent tool in doing data mining work!
what frustrated me recently is that when I using the function "svm" and using the "cross=10" parameters, I got all the "accuracies" of the model greater than 1. Isn't that the accuracy should be smaller than 1? so I wander how, the
2010 Jun 24
1
help in SVM
HI, GUYS,
I used the following codes to run SVM and get prediction on new data set hh.
dim(all_h)
[1] 2034 24
dim(hh) # it contains all the variables besides the variables in all_h
data set.
[1] 640 415
require(e1071)
svm.tune<-tune(svm, as.factor(out) ~ ., data=all_h,
ranges=list(gamma=2^(-5:5), cost=2^(-5:5)))# find the best parameters.
bestg<-svm.tune$best.parameters[[1]]
2006 Jan 31
2
SVM question
I'm running SVM from e1071 package on a data with ~150 columns (variables)
and 50000 lines of data (it takes a bit of time) for radial kernel for
different gamma and cost values.
I get a very large models with at least
30000 vectors and the prediction I get is not the best one. What does it
mean and what could I do to ameliorate my model ?
Jerzy Orlowski
2010 May 05
2
probabilities in svm output in e1071 package
svm.fit<-svm(as.factor(out) ~ ., data=all_h, method="C-classification",
kernel="radial", cost=bestc, gamma=bestg, cross=10) # model fitting
svm.pred<-predict(svm.fit, hh, decision.values = TRUE, probability = TRUE) #
find the probability, but can not find.
attr(svm.pred, "probabilities")
> attr(svm.pred, "probabilities")
1 0
1 0 0
2 0
2010 Apr 29
2
can not print probabilities in svm of e1071
> x <- train[,c( 2:18, 20:21, 24, 27:31)]
> y <- train$out
>
> svm.pr <- svm(x, y, probability = TRUE, method="C-classification",
kernel="radial", cost=bestc, gamma=bestg, cross=10)
>
> pred <- predict(svm.pr, valid[,c( 2:18, 20:21, 24, 27:31)],
decision.values = TRUE, probability = TRUE)
> attr(pred, "decision.values")[1:4,]
2004 Dec 21
2
Rgui.exe - Error while tuning svm
Hello,
if I try to tune my svm with the code:
Tune <- tune.svm(Data.Train, Class.Train, type="C-classification",
kernel="radial", gamma = 2^(-1:1), cost = 2^(2:4))
i get a windows Messagebox with a error in the application "Rgui.exe" and
the message: "Die Anweisung in 0x6c48174d verweist auf Speicher 0x00000000.
Der Vorgang "read" konnte nicht auf
2011 Mar 04
1
Probabilities outside [0, 1] using Support Vector Machines (SVM) in e1071
Hi All,
I'm attempting to use eps-regression or nu-regression SVM to compute
probabilities but the predict function applied to an svm model object
returns values outside [0, 1]:
Variable Data looks like:
Present X02 X03 X05 X06 X07 X13 X14 X15 X18
1 0 1634 48 2245.469 -1122.0750 3367.544 11105.013 2017.306 40 23227
2 0 1402 40 2611.519 -811.2500 3422.769 10499.425 1800.475 40 13822
3 0 1379
2010 Feb 23
1
e1071: Cannot predict probabilities
Dear list.
I using the SVM-methods from the e1071, but I can't get the
probabilities when predicting.
Code:
x <- matrix(rbinom(100, 10, 0.3), ncol=2)
y <- apply(x, 1, sum)
fit <- svm(y ~ x, method = "C-classification", kernel = "radial",
probability = TRUE)
predict(fit, x, probability=TRUE)
Here predict doesn't containing any probabilities (not as attributes
2008 Jan 02
1
Plot.svm error
Hi all,
Sorry to be bothering again with probably an easy error to fix, but I've been trying to solve the problem and haven't been able yet to do it. So I'm doing this:
> dados<-read.table("b.txt",sep="",nrows=30000)
>
2003 Dec 10
3
e1071:svm - default epsilon = 0.1 (NOT 0.5) (PR#5671)
In e1071 package/svm default epsilon value is set to 0.1 and not 0.5
as documentation says.
R