Filter löschen
Filter löschen

How can I set up the axis values in a plot?

1 Ansicht (letzte 30 Tage)
Agustin
Agustin am 5 Okt. 2017
Kommentiert: Agustin am 5 Okt. 2017
Hi! I'm working with some signal plots and I want to see how I can set up the axes so I can have a better view of the plots. For example, I have the attached plot:
How can I adjust the axes to have a more detailed view of the signals?
Thank you!

Akzeptierte Antwort

Cam Salzberger
Cam Salzberger am 5 Okt. 2017
Bearbeitet: Cam Salzberger am 5 Okt. 2017
Hello Agustin,
I'm not entirely certain what you mean by "a more detailed view of the signals". If you'd like to just thin out the line so that changes in direction are more visible, you can just add a 'LineWidth parameter when plotting. For example:
plot(rand(100,1), 'LineWidth', 0.2)
If you are looking to zoom in on various areas of interest, you can do that by modifying the axis limits. For example, for the second axes you might use:
xlim([18 40])
ylim([-2 2])
If the plots lend themselves to a different scale, you may get more detail out of them with logarithmic scale axes. For example, you could try plotting the first line with semilogy.
Of course, you can always make the figure window larger, either manually or by changing the 'Position' property of the figure. You can also pan and zoom on the plots manually using the tools in the toolbar.
Hope this helps.
-Cam

Weitere Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by