How to specify the order of panes in facet_wrap

In this tutorial, we will learn how to change the order of panes in a plot made with facet_wrap() or facet_grid(). We will use forcats package’s function fct_relevel() to specify the order we want while plotting. Let us make a scatterplot with facets using facet_wrap() function in ggplot2. Change order of plots in facet_wrap() with… Continue reading How to specify the order of panes in facet_wrap

How to Format Date in title text in ggplot2

In this tutorial, we will learn how to format date variables in the title text of a plot made with ggplot2. Sometimes one might want to write date in the title text. It is better to use the date as variable and format the way want, either full month or short month or full/partial days.… Continue reading How to Format Date in title text in ggplot2

Exit mobile version