SimpleMKL.classification: Simple MKL

Description Usage Arguments Value References Examples

View source: R/SimpleMKL.Classification.R

Description

This function conducts Simple MKL for precomputed gramm matrices

Usage

1
SimpleMKL.classification(k, outcome, penalty, tol = 10^(-4), max.iters = 1000)

Arguments

k

list of Gramm matrices

outcome

vector of binary outcome -1 and 1

penalty

ppenalty of the smoothness of the resulting desicion rules

tol

change between to iterations is smaller than this, algorithms is considered to have converged

max.iters

maximum number of allowed iteratons

Value

gamma weight vector for the importnace of each kernel

alpha coeffiencents of the dual of MKL

time total amount of time to train model

max.iters Numvber of iterations to reach convergence criteria

References

A Rakotomamonjy, FR Bach, S Canu, Y Grandvalet. Journal of Machine Learning Research 9 (Nov), 2491-2521.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
library(kernlab)
library(caret)
library(RMKL)
#Load data
data(benchmark.data)
example.data=benchmark.data[[1]]
# Split samples into training and test sets 
training.samples=sample(1:dim(example.data)[1],floor(0.7*dim(example.data)[1]),replace=FALSE)
# Set up cost parameters and kernels 
C=100
kernels=rep('radial',3)
degree=rep(0,3)
scale=rep(0,3)
sigma=c(0,2^seq(-3:0))
K=kernels.gen(example.data[,1:2], training.samples, kernels, degree, scale, sigma)
K.train=K$K.train
SimpleMKL.classification(K.train,example.data[training.samples,3], C)

cwilso6/RMKL documentation built on May 18, 2021, 9:58 a.m.