Reputation: 7973
I would like to execute the following command in MATLAB R2012a:
tform = affine2d([0.92387953 -0.38268343 0; 0.38268343 0.92387953 0; 2 3 1]);
I keep getting the following error :
Undefined function
'affine2d'
for input arguments of type'double'
.
It seems to expect it to be a function while actually it is a class.
Can someone please help me with this error?
Upvotes: 0
Views: 1316
Reputation: 104503
affine2d
was released as of MATLAB R2013a and is part of the Image Processing Toolbox. See the release notes here for more details and look under the R2013a section: http://www.mathworks.com/help/images/release-notes.html
Though you may have the Image Processing Toolbox, your version does not have affine2d
as you are using R2012a. The best equivalent is to use maketform
and its ilk. maketform
was replaced with affine2d
in R2013a as it is more robust and stable.
You either need to use maketform
or upgrade your version of MATLAB to at least R2013a or higher.
Good luck!
Upvotes: 1