Adding a secondary axis to a time series plot

Time series plots and scatterplots can be used with a secondary axis. Here, we will use the Oxford weather station's data to plot the temperature and hours of sunlight on the same chart. Temperature will be displayed on the left y axis; Sun(Hours) will be displayed on the right axis.

Getting ready

As done in the previous recipe, we will use the Oxford weather station's data. See the details in the Creating a time series plot recipe. Most of the steps in this example will be similar to the time series plot instructions, except the use of the multiple time series plots instead of a single one.

How to do it…

Let's get started with the steps that would help us add a secondary axis to a time series plot:

  1. Go ...

Get Minitab Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.