HTMLcopy
1
<div id="container"></div>
CSScopy
6
1
html, body, #container {
2
width: 100%;
3
height: 100%;
4
margin: 0;
5
padding: 0;
6
}
JavaScriptcopy
x
1
anychart.onDocumentReady(function () {
2
var dataSet = anychart.data.set([
3
['1986', 41, 36, 31],
4
['1987', 37, 34, 29],
5
['1988', 48, 47, 40],
6
['1989', 41, 39, 33],
7
['1990', 39, 36, 31],
8
['1991', 34, 31, 27],
9
['1992', 38, 35, 30],
10
['1993', 29, 28, 24],
11
['1994', 33, 32, 27]
12
]);
13
14
var chart = anychart.line();
15
16
chart.line(dataSet.mapAs({x: 0, value: 1}));
17
chart.line(dataSet.mapAs({x: 0, value: 2}));
18
chart.line(dataSet.mapAs({x: 0, value: 3}));
19
20
var a11y = chart.a11y();
21
22
// Set accessibility mode.
23
// Mode adds a hidden table available for VoiceOver.
24
// You can use inspect element tool to see the table
25
a11y.mode('data-table');
26
27
chart.title('Set accessibility mode DataTable');
28
chart.container('container');
29
chart.draw();
30
});