Compiler ignores the plot function in between the code and runs the next section which has the script.

6 vues (au cours des 30 derniers jours)
The image below shows the exact code that I am trying to execute. The issue is that the compiler misses/ignores the plot command (line 67) and directly goes to the user input command (line 78) in the next section. How can I run the code in the same sequence as it is? Thanking you in advace. The code is being run on the live script.

Réponse acceptée

Keshav
Keshav le 11 Avr 2023
Hi Ron,
I understand that you are trying to run the custom code but MATLAB is not generating any plot.
Try splitting your live code into sections and run it section by section for debugging. Or It might be possible that you may have previous plot open somewhere and MATLAB is plotting it on the same figure. You can use "close all" at the beginning of your script and try again.
Something like this
Close all
Your code goes here….
  1 commentaire
Ron
Ron le 14 Avr 2023
Thank you so much for your reply. Running the code section by section helped in solving the problem

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Graphics Objects dans Help Center et File Exchange

Produits


Version

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by