Gabor feature extraction from an image
<p>I am trying to extract gabor feature from an image using the gabor and imgaborfilt functions from image processing toolbox in matlab using the following code. But it keep giving me the error</p>

<blockquote>
  <p>Undefined function 'gabor' for input arguments of type <code>double</code></p>
</blockquote>

<p>This code is from <a href="http://au.mathworks.com/help/images/texture-segmentation-using-gabor-filters.html" rel="nofollow">http://au.mathworks.com/help/images/texture-segmentation-using-gabor-filters.html</a> just the image is changed. </p>

<pre><code>A=imread('101.jpg');
A = imresize(A,0.25);
Agray = rgb2gray(A);
imageSize = size(A);
numRows = imageSize(1);
numCols = imageSize(2);
wavelengthMin = 4/sqrt(2);
wavelengthMax = hypot(numRows,numCols);
n = floor(log2(wavelengthMax/wavelengthMin));
wavelength = 2.^(0:(n-2)) * wavelengthMin;
deltaTheta = 45;
orientation = 0:deltaTheta:(180-deltaTheta);
g = gabor(wavelength,orientation);
gabormag = imgaborfilt(Agray,g);
</code></pre>