Unable to perform assignment because the left and right side have a different number of elements

1 view (last 30 days)
I am using radio button callbacks in app designer to change variable values, and then proceed to plot with those new variables. I keep getting different errors including the one stating "the left and right side have a different number of elements" and "matrix dimensions must agree", but then sometimes it works just fine.
I think the issue might be with the callback function definition because it is intended to only take in one value but maybe its doing more than one and thats why the dimensions dont line up? Im not sure but thanks in advance for any assistance.
  9 Comments

Sign in to comment.

Answers (1)

Mohsin Zubair
Mohsin Zubair on 8 Jul 2021
You can compare and see what I have changed as I have commented out unnecessary parts, also there's another problem that is you must select sections in last, also you must change value of intensity, cause if you don't change it, it will cause an error because you used a value change callback to set its value so if you don't change value then its value remains unset which gives an error as well, (for which I would suggest directly assigning value of intensity in RUN callback)

Categories

Find more on Graphics Performance in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!