As part of understanding and fine tuning ggplot2’s theme elements, we will focus on the anatomy of line elements and see 15 tips to control them with ggplot2’s theme system. With ggplot2’s theme system we can control the “non-data” elements of a plot made with ggplot2. ggplot2’s theme system comes with multiple element_ functions, element_text() […]
10 Tips to Customize Text Color, Font, Size in ggplot2 with element_text()
ggplot2’s theme system give us a great control over how the “non-data” elements of a plot should look like. The theme system helps elevate the plot you make by making finer changes and make it easy to look better. ggplot2’s theme system comes with multiple element_ functions, element_text() element_line() element_rect() element_blank() And they help control […]
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 […]
Pandas map: Change Multiple Column Values with a Dictionary
In this tutorial, we will learn how to use Pandas map() 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. As we all know, there are multiple solutions to a problem. Pandas map() function works with Pandas […]