Seaborn v0.11.2 is here. It is a minor release that fixes issues and also has a few features. One of the useful features is the new convenient function “move_legend()” to change the position of legend in Seaborn. Before Seaborn v0.11.2, Matplotlib’s plt.legend() has been the go to function to change the position of legend in […]
Python
Pandas pct_change(): Add Colors to Percent with style
Pandas pct_change() function is a handy function that lets us calculate percent change between two rows or two columns easily. By default, pct_change() function works with adjacent rows and columns, but it can compute percent change for user defined period as well. One of the useful features of Pandas pct_change is to add annotation with […]
Lesser known Seaborn Tips and Tricks
Want to learn lesser known Seaborn tips and tricks from Micheal Waskom, the developer of Seaborn? Check out his periodical tweets since early this year. Stumbled upon this thread while searching for a specific Seaborn help and worked through some of the tips. Here are a few examples of lesser known Seaborn tips and tricks. […]
Pandas pct_change() to compute percent change across columns/rows
In this tutorial, we will see how to compute percent change for values in each column. Pandas’ pct_change() function will compute percent change for each value in a column when compared to the previous element in the column by default. Another way to think is Computes the percentage change from the immediately previous row Pandas’ […]
Pandas applymap(): Change values of Dataframe
Pandas applymap() is yet another useful function to change the content of a dataframe. In this tutorial, we will learn how to use Pandas applymap() function to replace multiple column values using a dictionary. Earlier, we saw how to use Pandas replace() function to change the values in multiple columns using dictionary. And then we […]