Tutorial 20. Interactive tutorial -- Making/reading scientific plots with less ambiguity
Learning objectives
- Recognize how the axis scale type, axis range, and other parameters can influence the appearance of a scientific plot.
- Tips for reading figures/ plotting figures with less ambiguity.
Background
Making scientific plots and reading scientific plots are essential skills for chemistry students. It is important to realize that we should pay attention to some subtleties of a plot to avoid being misguided by its appearance.
For example, a student in my class found a paradox for the appearance of the blackbody radiation curve.
We have learned about plotting the blackbody radiation equation in an earlier tutorial (Tutorial 11).
We can either plot the energy density function \(\rho(\nu,T)\) as a function of frequency \(\nu\), or as a function of wavelength \(\lambda\).
Try ploting (with ambiguity)
Instruction:
- First click “Activate” to activate the code block
- Once you see the buttons to “run” at the bottom left corner of the code block, click “run” to run the code. Please be patient. Starting the kernel can be slow sometimes.
- You will see two plots for the Planck’s radiation curves, as a function of \(\nu\) or \(\lambda\).
Paradox
Then here comes the paradox: We know and the relation between \(\nu\) and \(\lambda\) is \(\frac{c}{\mu} = \lambda\).
Therefore, we expect that the \(\rho\) curve should have different skews when we change the horizontal axis from \(\nu\) to \(\lambda\), i.e., the peak of the \(\nu\) plot is on the left side, and one expects the peak of the \(\lambda\) plot to be on the opposite side of the axis due to the reciprocal relation between \(\lambda\) and \(\nu\). However, we see that the peaks on both plots are on the left side of the horizontal axis. Why?
Answer
The reason is that the two plots are not directly comparable.
-
They are plotted at different temperatures. The \(\nu\) plot is plotted for $T=298 K$. The \(\lambda\) plot is plotted for \(T=5000k\). Although we focus on the \(\rho\) - \(\nu\) relationship, there is another parameter controlling the \(\rho\) function: the temperature. That information is given in the title of the plot.
-
They are plotted at different ranges of \(\nu\). The \(\nu\) plot is plotted for frequency in the range of 1 Hz to 1e15 Hz, as shown in the source code comments. The \(\lambda\) plot is plotted for the wavelength range of 100 nm to 1000 nm, corresponding to the frequency in the range of 3e15 Hz to 3e13 Hz. The ranges of frequencies are not the same in the two plots.
-
The \(\nu\) plot uses a log scale for the horizontal axis. The \(\lambda\) plot uses a linear scale for the horizontal axis. This difference further changed the appearance of the curves, making it hard to compare.
Take home messages
It’s easy to get confused when reading plots, or confuse the readers when making plots. Ask yourself the following questions when reading/making a plot:
- What is the range of the axes?
- What scale are the axes? Linear or log scale?
- Are there additional parameters that control the plot other than the variables shown on the axis?
When reading the plots in publications, carefully read the captions and axis labels to avoid misunderstanding the plot.
When making plots for your homework, or research projects, make sure that we provide all the information clearly to make the reader understand what you mean to present.