?? kdist.html
字號(hào):
<html><head> <meta HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=ISO-8859-1"> <title>Contents.m</title><link rel="stylesheet" type="text/css" href="../stpr.css"></head><body><table border=0 width="100%" cellpadding=0 cellspacing=0><tr valign="baseline"><td valign="baseline" class="function"><b class="function">KDIST</b><td valign="baseline" align="right" class="function"><a href="../kernels/index.html" target="mdsdir"><img border = 0 src="../up.gif"></a></table> <p><b>Computes distance between vectors in kernel space.</b></p> <hr><div class='code'><code><span class=help></span><br><span class=help> <span class=help_field>Synopsis:</span></span><br><span class=help> d = kdist(X,model)</span><br><span class=help></span><br><span class=help> <span class=help_field>Description:</span></span><br><span class=help> It computes distance between vectors mapped into the feature </span><br><span class=help> space induced by the kernel function (model.options.ker,</span><br><span class=help> model.options.arg). The distance is computed between images</span><br><span class=help> of vectors X [dim x num_data] mapped into feature space</span><br><span class=help> and a point in the feature space given by model:</span><br><span class=help></span><br><span class=help> d(i) = kernel(X(:,i),X(:,i)) </span><br><span class=help> - 2*kernel(X(:,i),models.sv.X)*model.Alpha + b,</span><br><span class=help></span><br><span class=help> where b [1x1] is assumed to be equal to </span><br><span class=help> model.b = model.Alpha'*kernel(model.sv.X)*model.Alpha.</span><br><span class=help></span><br><span class=help> <span class=help_field>Input:</span></span><br><span class=help> X [dim x num_data] Input vectors.</span><br><span class=help> model [struct] Deternines a point of the feature space:</span><br><span class=help> .Alpha [nsv x 1] Multipliers.</span><br><span class=help> .sv.X [dim x nsv] Vectors.</span><br><span class=help> .b [1x1] Bias.</span><br><span class=help> .options.ker [string] Kernel identifier (see 'help kernel').</span><br><span class=help> .options.arg [1 x nargs] Kernel argument(s).</span><br><span class=help></span><br><span class=help> <span class=help_field>Output:</span></span><br><span class=help> d [num_data x 1] Distance between vectors in the feature space.</span><br><span class=help></span><br><span class=help> <span class=help_field>Example:</span></span><br><span class=help> data = load('riply_trn');</span><br><span class=help> model.Alpha = dualmean(size(data.X,2));</span><br><span class=help> model.sv.X = data.X;</span><br><span class=help> model.options.ker = 'rbf';</span><br><span class=help> model.options.arg = 0.25;</span><br><span class=help> model.b = model.Alpha'*kernel(data.X,'rbf',0.25)*model.Alpha;</span><br><span class=help> [Ax,Ay] = meshgrid(linspace(-5,5,100), linspace(-5,5,100));</span><br><span class=help> dist = kdist([Ax(:)';Ay(:)'],model);</span><br><span class=help> figure; hold on; </span><br><span class=help> ppatterns(data.X); contour( Ax, Ay, reshape(dist,100,100));</span><br><span class=help> </span><br><span class=help> <span class=also_field>See also </span><span class=also></span><br><span class=help><span class=also> <a href = "../kernels/minball.html" target="mdsbody">MINBALL</a>.</span><br><span class=help></span><br></code></div> <hr> <b>Source:</b> <a href= "../kernels/list/kdist.html">kdist.m</a> <p><b class="info_field">About: </b> Statistical Pattern Recognition Toolbox<br> (C) 1999-2003, Written by Vojtech Franc and Vaclav Hlavac<br> <a href="http://www.cvut.cz">Czech Technical University Prague</a><br> <a href="http://www.feld.cvut.cz">Faculty of Electrical Engineering</a><br> <a href="http://cmp.felk.cvut.cz">Center for Machine Perception</a><br> <p><b class="info_field">Modifications: </b> <br> 25-aug-2004, VF, MINBALL added to See also <br> 16-may-2004, VF<br> 26-feb-2003, VF<br> 13-sep-2002, VF<br> 15-jun-2002, VF<br></body></html>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -