MATLAB Answers

run code sections in matlab R2017b.

11 views (last 30 days)
Claudio Altafini
Claudio Altafini on 30 Oct 2017
Commented: Chad Greene on 28 Feb 2018
when I run a code section, matlab R2017b now check for errors in the entire script, not just on the section to be executed (as it used to be in older versions). Is this a bug or is it in purpose?
I am using mac OS Sierra 10.12.6 (if that is of any relevance)
thanks. Claudio
Claudio Altafini
Claudio Altafini on 31 Oct 2017
It is not a parenthesis mismatch or something similar. The following standard 2-section matlab example gives me error (use to work under R2016b). Thanks for any suggestion. Claudio
%%Calculate and Plot Sine Wave
x = 0:1:6*pi;
y = sin(x);
%%Modify Plot Properties
title('Sine Wave')

Sign in to comment.

Answers (1)

Prasanth Sunkara
Prasanth Sunkara on 28 Nov 2017
Hello Claudio,
This behavior is by design. Having this capability allows section evaluation to access local functions which seems desirable.
Chad Greene
Chad Greene on 28 Feb 2018
What a frustrating design change! Any chance we'll ever get a Preference option to change it back?

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!