import seaborn as sns; sns.set_theme()

penguins = sns.load_dataset("penguins")
sns.ecdfplot(data=penguins, x="flipper_length_mm")

"""
Explanation: Plot a univariate distribution along the x axis:
End of explanation
"""


sns.ecdfplot(data=penguins, y="flipper_length_mm")

"""
Explanation: Flip the plot by assigning the data variable to the y axis:
End of explanation
"""


sns.ecdfplot(data=penguins.filter(like="bill_", axis="columns"))

"""
Explanation: If neither x nor y is assigned, the dataset is treated as wide-form, and a histogram is drawn for each numeric column:
End of explanation
"""


sns.ecdfplot(data=penguins, x="bill_length_mm", hue="species")

"""
Explanation: You can also draw multiple histograms from a long-form dataset with hue mapping:
End of explanation
"""


sns.ecdfplot(data=penguins, x="bill_length_mm", hue="species", stat="count")

"""
Explanation: The default distribution statistic is normalized to show a proportion, but you can show absolute counts instead:
End of explanation
"""


sns.ecdfplot(data=penguins, x="bill_length_mm", hue="species", complementary=True)

"""
Explanation: It's also possible to plot the empirical complementary CDF (1 - CDF):
End of explanation
"""


