Hi all,
quite frequently I am working with signals which jump from one constant value to another over the course of the simulation time, so are mostly horizontal. When I then open a scope and press 'autoscale', because the signals have different ranges of values, big chunks of the signal 'disappear' in the upper or lower axis limit (mainly y-axis). That means that I have to adjust the limits manually every time to see the whole signal and not just a vertical line somewhere in the plot. (It gets annoying after a while)
Is there a way to (automatically or semi-automatically) insert some sort of margin at the top and at the bottom, when using autoscale, so that I can see the whole signal in my Simulink scope?
Or is there a suitable workaround?
Thank you in advance
Manuel

 Réponse acceptée

Ameer Hamza
Ameer Hamza le 24 Mar 2020

0 votes

Autoscale should change the axis limits such that the complete signal is visible. If you are need manually scale axis every time even after clicking autoscale, then I suggest using the auto option for the axes scaling in the scope setting. In the scope window, go to View > Configuration Properties and in the axis scaling field, change from manual to auto. However, note that if you manually try to change the axis limits afterward, then this setting will revert to the manual.

5 commentaires

Manuel Gossen
Manuel Gossen le 25 Mar 2020
Thank you for the advice. Unfortunately I am using 2013b and I don't have that menu available to me (see picture).
This is how my Scope looks like after I press autoscale (e.g because the axis retain the settings from the previous simulation and the signal might then have had a different range of values). The shown signal drops from 1 to 0 but I can't properly see that until I adjust the y-axis.
Ameer Hamza
Ameer Hamza le 25 Mar 2020
Maybe this issue is related to older versions on MATLAB. Can't you just autoscale the y-axis by pressing this button instead of manually changing the limits.
Manuel Gossen
Manuel Gossen le 25 Mar 2020
I'm afraid the button doesn't autoscale, it limits the manual zoom to the y-axis. That works fine to specify the viewing range if the whole signal is visible in the first place.
I have observed that autoscale doesn't always set the axis limits exactly to the max/min values of the signal but a round numer near it. If the signal happens to have that very value, it disappears on the limit.
Ameer Hamza
Ameer Hamza le 25 Mar 2020
In that case, I guess that this is an issue present in older versions of MATLAB. The only solution might be to update to a latest release.
Manuel Gossen
Manuel Gossen le 25 Mar 2020
That's unfortunate, because for this project I am stuck to 2013b, so that is not an option for me.
Thank you anyways.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur General Applications dans Centre d'aide et File Exchange

Produits

Version

R2013b

Community Treasure Hunt

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

Start Hunting!

Translated by