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.pyramid([
3
{x: 'Physical', value: 59.2},
4
{x: 'Data Link', value: 24.9},
5
{x: 'Network', value: 8.9},
6
{x: 'Transport', value: 3.8},
7
{x: 'Session', value: 1.9},
8
{x: 'Presentation', value: 1.8},
9
{x: 'Application', value: 1.4}
10
]);
11
12
// Enable overlap mode.
13
chart.overlapMode('allow-overlap');
14
15
chart.title('Enable overlap mode');
16
chart.container('container');
17
chart.draw();
18
});