HTMLcopy
1
<button id="xmlButton" onclick="showXml()">Show XML config</button>
2
<div id="container"></div>
CSScopy
15
1
html, body {
2
width: 100%;
3
height: 100%;
4
margin: 0;
5
padding: 0;
6
}
7
button {
8
margin: 10px 0 0 10px;
9
}
10
#container {
11
position: absolute;
12
width: 100%;
13
top: 35px;
14
bottom: 0;
15
}
JavaScriptcopy
x
1
anychart.onDocumentReady(function () {
2
// chart type
3
chart = anychart.polar();
4
5
chart.title().text("Polar Chart");
6
7
chart.line([
8
{x: 0, value: 0},
9
{x: 10, value: 1},
10
{x: 20, value: 2},
11
{x: 30, value: 3},
12
{x: 40, value: 4},
13
{x: 50, value: 5},
14
{x: 60, value: 6},
15
{x: 70, value: 7},
16
{x: 80, value: 8},
17
{x: 90, value: 9},
18
{x: 100, value: 10}
19
]).tooltip().enabled(false);
20
21
chart.xScale().maximum(100).ticks().interval(10);
22
23
chart.yScale().ticks().interval(2);
24
25
chart.xAxis().labels().fontWeight(900);
26
chart.container("container").draw();
27
});
28
29
function showXml(){
30
alert(chart.toXml());
31
};