How To Color Scatterplot by a variable in Matplotlib?

Coloring Scatterplot with Variable using Matplotlib

Scatterplots between two numerical variables are great to see the relationship between them. Adding colors to the data points based on the third categorical variable is often useful in understanding the relationship among the three variables. In this post, we will learn how to color data points in a scatterplot by a third categorical variable… Continue reading How To Color Scatterplot by a variable in Matplotlib?

How To Adjust Positions of Axis Labels in Matplotlib?

How To Adjust Axes Label Position in Matplotlib?

In this post, we will learn how to adjust positions of x-axis and y-axis labels in Matplotlib in Python. By default, plots with matplotlib places the axis labels in the middle. With matplotlib version 3.3.0, the matplotlib functions set_xlabel and set_ylabel have a new parameter “loc” that can help adjust the positions of axis labels.… Continue reading How To Adjust Positions of Axis Labels in Matplotlib?

How To Place Legend Outside the Plot with Seaborn in Python?

Move Legend to Outside Plot Seaborn

While making plots with legend, like scatterplot, Seaborn has a nice feature that finds a suitable place for legend and puts it automatically inside the plot. This greatly helps in utilizing plotting area efficiently. However, sometimes you might want the legend outside the plot. In this tutorial, we will see an example of how to… Continue reading How To Place Legend Outside the Plot with Seaborn in Python?

How to Show Mean on Boxplot using Seaborn in Python?

Customize Mean Mark in Boxplot: Seaborn & Matplotlib

Boxplots show five summary statistics, including median, derived from data to show distribution of numerical data corresponding categorical variables. Sometimes, you might want to highlight the mean values in addition to the five statistics of boxplot. In this post we will see how to show mean mark on boxplot using Seaborn in Python. We will… Continue reading How to Show Mean on Boxplot using Seaborn in Python?

How To Annotate Bars in Barplot with Matplotlib in Python?

How To Annotate Bars in Seaborn Barplot with Matplotlib?

In this post we will learn examples of adding text, annotating bars in barplot using matplotlib. We will make bar plots using Seaborn’s barplot and use Matplotlib to add annotations to the bars in barplot. Let us load Pandas, Seaborn and Matplotlib. Let us create a toy dataset using two lists. And create a Pandas… Continue reading How To Annotate Bars in Barplot with Matplotlib in Python?

Exit mobile version