python how to set the axis ranges in seaborn

Solutions on MaxInterview for python how to set the axis ranges in seaborn by the best coders in the world

showing results for - "python how to set the axis ranges in seaborn"
Tess
20 Jun 2018
1# Short answer:
2# Seaborn uses matplotlib, so you can set the axes in the same way with
3# plt.xlim(lower, upper) and plt.ylim(lower, upper)
4
5# Example usage:
6import seaborn as sns
7import matplotlib.pyplot as plt
8sns.set_style("whitegrid")
9tips = sns.load_dataset("tips")
10sns.boxplot(x="day", y="total_bill", data=tips)
11plt.ylim(5, 45)