qrsvm: Fits a quantile regression SVM based on the Pinball Loss

Description Usage Arguments Details Value References Examples

View source: R/qrsvm.R

Description

Fits a quantile regression SVM based on the Pinball Loss

Usage

1
2
qrsvm(x, y, kernel = "rbfdot", cost = 1, tau = 0.95, sigma = 5,
  degree = 2, scale = 1, offset = 1, order = 1)

Arguments

x

An n X m matrix containing the predictors (n= number of observatiosn, m = number of predictors) .

y

The Response onto which the qrsvm shall be fitted

kernel

a string giving the type of kernels from package kernlab to use f.e. "rbfdot" for Radial Basis Function Kernel. All Kernels except "stringdot" supported.

cost

The Cost parameter see f.e. package "e1071" and "kernlab"

tau

The Quantile that shall be estimated. 0<=tau<=1

sigma

A possible tuning parameter for specific Kernelfunctions, see package kernlab.

degree

A possible tuning parameter for specific Kernelfunctions, see package kernlab.

scale

A possible tuning parameter for specific Kernelfunctions, see package kernlab.

offset

A possible tuning parameter for specific Kernelfunctions, see package kernlab.

order

A possible tuning parameter for specific Kernelfunctions, see package kernlab.

Details

There is no preimplemented scaling of the input variables which should be considered beforehand. Also optimization is based on "quadprog:solve.QP" function which can be considerably slow compared to other SVM implementations.

Value

An object of class "qrsvm"

References

"Nonparametric Quantile Regression" by I.Takeuchi, Q.V. Le, T. Sears, A.J. Smola (2004)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
n<-200

x<-as.matrix(seq(-1.5,1.5,length.out = n))
y<-rnorm(n)*(0.3+abs(sin(x)))

plot(x,y)

mod005<-qrsvm(x,y, tau=0.05)
mod095<-qrsvm(x,y, tau=0.95)
lines(x, mod005$fitted, col="red")
lines(x, mod095$fitted, col="red")

Example output



qrsvm documentation built on May 2, 2019, 4:02 p.m.

Related to qrsvm in qrsvm...