Fix flaky testCustomBarsWithNegativeValuesInLogScale. DygraphLayout._calcYNormal...
[dygraphs.git] / tests / numeric-gviz.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7; IE=EmulateIE9">
5 <title>numeric gviz</title>
6 <!--[if IE]>
7 <script type="text/javascript" src="../excanvas.js"></script>
8 <![endif]-->
9 <!--
10 For production (minified) code, use:
11 <script type="text/javascript" src="dygraph-combined.js"></script>
12 -->
13 <script type="text/javascript" src="../dygraph-dev.js"></script>
14
15
16 <script type="text/javascript" src="http://www.google.com/jsapi"></script>
17
18 <script type="text/javascript">
19 google.load("visualization", "1", {"packages":[ "columnchart"]});
20 google.setOnLoadCallback(drawchart);
21
22 function drawchart() {
23 var tableString =
24 "{cols:[{id:'point',label:'n',type:'number',pattern:''}," +
25 "{id:'0',label:'0',type:'number',pattern:''}," +
26 "{id:'stddev',label:'stddev',type:'number',pattern:''}]," +
27 "rows:[{c:[{v:0.0},{v:41.97},{v:17.86}]},{c:[{v:1.0},{v:11.71},{v:17.86}]},{c:[{v:2.0},{v:43.26},{v:17.86}]}]}";
28 data = new google.visualization.DataTable(eval('(' + tableString + ')'));
29 chart = new Dygraph.GVizChart(document.getElementById(
30 "graph"));
31 chart.draw(data, {errorBars: true, showRoller: true, includeZero: true });
32 }
33 </script>
34 </head>
35 <body>
36 <p>This tests that dygraphs can display gviz DataTable's with a numeric
37 x-axis.</p>
38 <div id="graph" style="width: 800px; height: 400px;"></div>
39 </body>
40 </html>