Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Error while evaluating uicontrol Callback
Replies: 1   Last Post: Mar 14, 2013 9:22 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View  
Yair Altman

Posts: 1,347
Registered: 3/19/07
Re: Error while evaluating uicontrol Callback
Posted: Mar 14, 2013 9:22 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

"Yuwei " <wyw0424@ksu.edu> wrote in message <khte06$k1m$1@newscl01ah.mathworks.com>...
> I don't understand this error. The first function for 'parabola' is correct but the second one doesn't work. Can anyone explain to me? Thank you so much!
[snip]
> Error using ==
> Matrix dimensions must agree.
>
> Error in WYW_ctfsBuilder (line 44)
> if sigType == 'parab' % parabola
>
> Error in WYW_ctfsBuilder/square_Callback (line 38)
> WYW_ctfsBuilder('square');
>
> Error while evaluating uicontrol Callback



You cannot compare strings with == - you need to use strcmp() or some other string-comparison function:
if strcmpi(sigType,'parab')

Yair Altman
http://UndocumentedMatlab.com




Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.