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 chart = anychart.surface();
3
4
// Set data.
5
chart.data([
6
{x: -1.8, y: -1.8, z: -46.656000000000006},
7
{x: -1.8, y: -0.8, z: -17.576000000000004},
8
{x: -1.8, y: 0.19999999999999996, z: -4.096000000000001},
9
{x: -1.8, y: 1.2, z: -0.21600000000000008},
10
{x: -0.8, y: -1.8, z: -17.576000000000004},
11
{x: -0.8, y: -0.8, z: -4.096000000000001},
12
{x: -0.8, y: 0.19999999999999996, z: -0.21600000000000008},
13
{x: -0.8, y: 1.2, z: 0.06399999999999996},
14
{x: 0.19999999999999996, y: -1.8, z: -4.096000000000001},
15
{x: 0.19999999999999996, y: -0.8, z: -0.21600000000000008},
16
{x: 0.19999999999999996, y: 0.19999999999999996, z: 0.06399999999999996},
17
{x: 0.19999999999999996, y: 1.2, z: 2.7439999999999993},
18
{x: 1.2, y: -1.8, z: -0.21600000000000008},
19
{x: 1.2, y: -0.8, z: 0.06399999999999996},
20
{x: 1.2, y: 0.19999999999999996, z: 2.7439999999999993},
21
{x: 1.2, y: 1.2, z: 13.824}
22
]);
23
24
chart.title('Set chart data as an array of objects');
25
chart.container('container');
26
chart.draw();
27
});