Command window output not displaying everything?

17 visualizaciones (últimos 30 días)
Cole Butler
Cole Butler el 22 de Jul. de 2019
Comentada: Cole Butler el 22 de Jul. de 2019
The command window does not display all of the output in my code. This is a very recent problem, not sure what I could have done to start it. As an example, sometimes I want to see how the variable "a" changes in a loop, so I will include a line of code that says
disp(a);
Usually, I'd be able to see all of the outputs. For example, if I was counting to 100, I'd be able to see the output 1,2,3, etc. Recently, however, MATLAB "deletes" all of the outputs except the very last output, so I only see
a =
100
Any other output is unable to be accessed by hitting the up arrow. It seems that MATLAB will momentarily display it, but then it disappears. Anybody know what to do? Not sure where this problem came from, or how to fix it. I've checked out the preferences for command window, but "Automatically delete output?" does not seem to be an option. Cheers.
  2 comentarios
Adam
Adam el 22 de Jul. de 2019
What else is in your code? Do you have the ghastly
clc
sitting somewhere in code called within your loop?
Cole Butler
Cole Butler el 22 de Jul. de 2019
Yes, that was it! It seemed that at one point I thought I was typing in the command window and was instead typing in the editor... how embarrassing. Thank you!!

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre MATLAB en Help Center y File Exchange.

Etiquetas

Productos


Versión

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by