Creating Box and Whisker Chart

A box and whisker chart is used to examine a given set of data and draw the statistical conclusion using the five-number summary principle.

In this section, you will be shown how you can:

  • Create a simple box and whisker chart

  • Use legends in the box and whisker chart

Creating a Simple Box and Whisker Chart

As an example, we will create a box and whisker chart that shows the gender-wise distribution of annual salaries.

The box and whisker chart thus created looke like this:

FusionCharts should load here..

In the chart shown above, note that the minimum and maximum values and the median are displayed by default, whereas the upper and lower quartile values are hidden.

Given below is a brief description of the attributes used to create a box and whisker chart:

Attribute Name Description
seriesName It is used to specify the series name for a dataset. For example, you can name the dataset for the male employee salaries ‘Male’. This attribute belongs to the dataset object.
lowerBoxColor It is used to specify the hex code of the color that will be used to render the lower quartile box. This attribute belongs to the dataset object.
upperBoxColor It is used to specify the hex code of the color that will be used to render the upper quartile box. This attribute belongs to the dataset object.
value It is used to specify a comma-separated list of values for each item in the dataset. This attribute belongs to the data object, which belongs to the dataset object. The comma is the default data-separator. You can explicitly specify the data-separator using the dataSeparator attribute. For example, "dataSeparator”: "|”. This attribute belongs to the data object, which belongs to the dataset object.

The data structure needed to create a box and whisker chart is given below:

...

There! You have now seen how you can create a simple box and whisker chart.