3 <title>label-div
</title>
5 <script type=
"text/javascript" src=
"../excanvas.js"></script>
7 <script type=
"text/javascript" src=
"../strftime/strftime-min.js"></script>
8 <script type=
"text/javascript" src=
"../rgbcolor/rgbcolor.js"></script>
9 <script type=
"text/javascript" src=
"../dygraph-canvas.js"></script>
10 <script type=
"text/javascript" src=
"../dygraph.js"></script>
11 <script type=
"text/javascript" src=
"data.js"></script>
14 <p>Chart with labels displayed in a separate div:
</p>
16 <td valign=
"top"><div id=
"graphdiv2"></div></td>
17 <td valign=
"top"> </td>
18 <td valign=
"top"><div id=
"labels"></div></td>
21 The following chart should be the same as above. Here we use the
22 labelsDiv id instead of the actual labelsDiv element.
<br/>This is
23 useful when the labelsDiv element has not been attached to the
24 DOM when the chart/options is created:
27 <td valign=
"top"><div id=
"graphdiv3"></div></td>
28 <td valign=
"top"> </td>
29 <td valign=
"top"><div id=
"labels2"></div></td>
32 The following chart shows the labelsShowZeroValues option in use.
33 When any point has a zero value the label is not shown. This is
34 useful when there are many zero values in a point and the user
35 is only interested in the non-zero points.
38 <td valign=
"top"><div id=
"graphdiv4"></div></td>
39 <td valign=
"top"> </td>
40 <td valign=
"top"><div id=
"labels3"></div></td>
43 <script type=
"text/javascript">
44 g2 = new Dygraph(document.getElementById(
"graphdiv2"),
47 labels: [
"Date",
"High",
"Low" ],
48 labelsDiv: document.getElementById(
"labels")
50 g3 = new Dygraph(document.getElementById(
"graphdiv3"),
53 labels: [
"Date",
"High",
"Low" ],
56 g4 = new Dygraph(document.getElementById(
"graphdiv4"),
59 labels: [
"Date",
"High",
"Low" ],
61 labelsShowZeroValues: false