Emprise Javascript Charts

Area Chart Example

Description

This is an example of a simple area chart. It demonstrates use of the custom defined title, x_axis_caption, y_axis_caption, show_options, color, and show_hints properties. These allow for the display of the custom title, x axis caption, and y axis caption, a light brown colored series, and the disabling of the hints. A custom series title is added as well.

Source Code

  1. <script type=”text/javascript”>
  2.       var myChart2 = new EJSC.Chart( ‘myChart1a’ , {
  3.                            title: “Sample Area Chart” ,
  4.                            axis_bottom: { caption: “Frequency (Hz)” } ,
  5.                            axis_left: { caption: “Velocity (in/s)” } ,
  6.                            show_hints: false } );
  7.         myChart2.addSeries( new EJSC.AreaSeries( new EJSC.XMLDataHandler(“vibration2_area.xml”) ,
  8.                                       { title: “Area 1”,
  9.                                        color: ‘rgb(255,222,173)’} ) );
  10. </script>
Spread the love