How to change the axes limits of a matplotlib figure || Matplotlib Tips

preview_player
Показать описание
This matplotlib axes limits tutorial provides matplotlib tips on how to change both x- and y-limits for a matplotlib figure. I first demonstrate how matplotlib updates axes limits using pyplot functions: plt xlim and plt ylim. I also adjust only one limit using None as an argument and the bottom keyword. Then I show you how to get your current axes to do matplotlib set_xlim and set_ylim. This method may prove useful for controlling matplotlib subplot axes limits. Finally, I demonstrate Python code that allows you to use matplotlib to get the axes limits and then produce a matplotlib reverse axis.

0:00 Introduction
1:11 Adjusting only one limit
3:49 Getting & reversing axes limits

Github Code:

Related Videos:

#matplotlib #dataviz #matplotlibtips
Рекомендации по теме
Комментарии
Автор

how do you control the x-axis if it's a series of dates?

lakeguy
visit shbcf.ru