PRTools Contents

PRTools User Guide

kernelc

KERNELC

Arbitrary kernel/dissimilarity based classifier

    W = KERNELC(A,KERNEL,CLASSF)
    W = A*KERNELC([],KERNEL,CLASSF)
    W = A*KERNELC(KERNEL,CLASSF)

Input
 A Dateset used for training
 KERNEL untrained mapping to compute kernel by A*(A*KERNEL) for  training CLASSF or B*(A*KERNEL) for testing with dataset B, or
-  trained mapping to compute a kernel A*KERNEL for training
 CLASSF or B*KERNEL for testing with a dataset B
 KERNEL should be a functions like PROXM, KERNELM or USERKERNEL.  Default: reduced dissimilarity representation:  KERNELM([],[],'random',0.1,100);
 CLASSF Classifier used in kernel space, default LOGLC.

Output
 W Resulting, trained classifier

Description

This routine defines a classifier W in the input feature space based  on a kernel or dissimilarity representation defined by KERNEL and a  classifier CLASSF to be trained in the kernel space.

In case KERNEL is defined by V = KERNELM( ... ) this routine  is identical to W = A*(V*CLASSF), Note that if KERNEL is a mapping, it  may be trained as well as untrained. In the latter case A is used to  build the kernel space as well as to optimise the classifier (like in SVC).

Example(s)

 a = gendatb([100 100]);    % training set of 200 objects
 r = gendatb([10 10]);      % representation set of 20 objects
 v = proxm(r,'p',3);        % compute kernel
 w = kernelc(a,v,fisherc)   % compute classifier
 scatterd(a);               % scatterplot of trainingset
 hold on; scatterd(r,'ko'); % add representation set to scatterplot
 plotc(w);                  % plot classifier

See also

datasets, mappings, kernelm, proxm, userkernel,

PRTools Contents

PRTools User Guide

This file has been automatically generated. If badly readable, use the help-command in Matlab.