O'Reilly logo

Beginning JavaScript Charts: With jqPlot, d3, and Highcharts by Fabio Nelli

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 5

image

Drawing a Bar Chart

In the previous chapter, you created a line chart, using the data in an HTML table. However, the same data can be represented by other charts, including the well-known bar chart. With this type of data visualization, you still have the two axes (x and y), but x, instead of being represented as a continuous scale of values, is used to represent groups, which may or may not follow an increasing trend.

In this chapter, you will continue to use the code written in the previous chapter, and you will see how, by making a few changes to the code (very few!), you can convert your line chart into a bar chart. Once you have ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required