| cndkernmatrix {qkerntool} | R Documentation |
CND Kernel Matrix functions
Description
cndkernmatrix calculates the kernel matrix K_{ij} = k(x_i,x_j) or K_{ij} =
k(x_i,y_j).
Usage
## S4 method for signature 'cndkernel'
cndkernmatrix(cndkernel, x, y = NULL)
Arguments
cndkernel |
the cndkernel function to be used to calculate the CND kernel
matrix.
This has to be a function of class |
x |
a data matrix to be used to calculate the kernel matrix. |
y |
second data matrix to calculate the kernel matrix. |
Details
Common functions used during kernel based computations.
The cndkernel parameter can be set to any function, of class
cndkernel, which computes the kernel function value in feature space between two
vector arguments. qkerntool provides more than 10 CND kernel functions
which can be initialized by using the following
functions:
-
nonlcndNon Linear cndkernel function -
polycndPolynomial cndkernel function -
rbfcndGaussian cndkernel function -
laplcndLaplacian cndkernel function -
anocndANOVA cndkernel function -
raticndRational Quadratic cndkernel function -
multcndMultiquadric cndkernel function -
invcndInverse Multiquadric cndkernel function -
wavcndWave cndkernel function -
powcndd cndkernel function -
logcndLog cndkernel function -
caucndCauchy cndkernel function -
chicndChi-Square cndkernel function -
studcndGeneralized T-Student cndkernel function
(see example.)
Value
cndkernmatrix returns a conditionally negative definite matrix with a zero diagonal element.
Author(s)
Yusen Zhang
yusenzhang@126.com
See Also
nonlbase, rbfbase,
laplbase, ratibase, multbase, invbase,
wavbase, powbase, logbase, caubase,
chibase, studbase
Examples
## use the iris data
data(iris)
dt <- as.matrix(iris[ ,-5])
## initialize cndkernel function
lapl <- laplcnd(gamma = 1)
lapl
## calculate cndkernel matrix
cndkernmatrix(lapl, dt)