Tuesday, January 15, 2013

Business analytics - Time series analysis - Retail data


Working with Soft drinks sales data (Section 2.3)

The images produced to analyze the time series are not standard R graphics. As such I needed to dig a little deeper to replicate them. The were two tricks required to replicate this,

  1. How to draw one plot over another.
  2. How to use the same axis definition for all three plots. (these are hard coded).

While researching this I noticed that thi=s example does not even scratch the surface of R's capabilities for handling time series. However perhaps these are covered later. Anyhow here is the image
As explained the sales figure can be seen to have a periodic element and growth element - possibly exponential. Plotting the simpler unenhanced plot side by sided requires the layout command. I may do this later, but now it is time to move on.

Further reading