January 10, 2017

Summary

This is an example of the use of Plotly to visualize several dimensions in two data sets in one scatterplot. The ChickWeight and Airquality data sets will be used as examples.

In the first plot, using the Airquality data set, the Ozone level (in parts per billion) is plotted against temparature (in degrees Farenheit), with Month used as a factor variable shown as marker color, and size reflecting the value of 'Solar.R' (Solar radiation in Langleys in the frequency band 4000-7700 Angstroms from 8:00-12:00 at Central Park). The corresponding 'Wind' value is pasted as text into the marker hover-over text.

In the second plot, using the ChickWeight data set, Chick Weight is plotted against Time in days, with Diet Type (1-4) used as a factor variable determining color and line type. The Chick ID is pasted in the marker popup text. ('Chick' is an ordered factor with levels 18 < … < 48 giving a unique identifier for the chick. The ordering of the levels groups chicks on the same diet together and orders them according to their final weight (lightest to heaviest) within diet.)

Data Visualization - Air Quality

Data Visualization - Chick Weight

The end

  • Thanks!