| 9 |
lars |
1 |
<!DOCTYPE HTML>
|
|
|
2 |
<html>
|
|
|
3 |
<head>
|
|
|
4 |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
|
5 |
<title>Highcharts Example</title>
|
|
|
6 |
|
|
|
7 |
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
|
|
|
8 |
<style type="text/css">
|
|
|
9 |
${demo.css}
|
|
|
10 |
</style>
|
|
|
11 |
<script type="text/javascript">
|
|
|
12 |
$(function () {
|
|
|
13 |
$('#container').highcharts({
|
|
|
14 |
chart: {
|
|
|
15 |
type: 'area'
|
|
|
16 |
},
|
|
|
17 |
title: {
|
|
|
18 |
text: 'US and USSR nuclear stockpiles'
|
|
|
19 |
},
|
|
|
20 |
subtitle: {
|
|
|
21 |
text: 'Source: <a href="http://thebulletin.metapress.com/content/c4120650912x74k7/fulltext.pdf">' +
|
|
|
22 |
'thebulletin.metapress.com</a>'
|
|
|
23 |
},
|
|
|
24 |
xAxis: {
|
|
|
25 |
allowDecimals: false,
|
|
|
26 |
labels: {
|
|
|
27 |
formatter: function () {
|
|
|
28 |
return this.value; // clean, unformatted number for year
|
|
|
29 |
}
|
|
|
30 |
}
|
|
|
31 |
},
|
|
|
32 |
yAxis: {
|
|
|
33 |
title: {
|
|
|
34 |
text: 'Nuclear weapon states'
|
|
|
35 |
},
|
|
|
36 |
labels: {
|
|
|
37 |
formatter: function () {
|
|
|
38 |
return this.value / 1000 + 'k';
|
|
|
39 |
}
|
|
|
40 |
}
|
|
|
41 |
},
|
|
|
42 |
tooltip: {
|
|
|
43 |
pointFormat: '{series.name} produced <b>{point.y:,.0f}</b><br/>warheads in {point.x}'
|
|
|
44 |
},
|
|
|
45 |
plotOptions: {
|
|
|
46 |
area: {
|
|
|
47 |
pointStart: 1940,
|
|
|
48 |
marker: {
|
|
|
49 |
enabled: false,
|
|
|
50 |
symbol: 'circle',
|
|
|
51 |
radius: 2,
|
|
|
52 |
states: {
|
|
|
53 |
hover: {
|
|
|
54 |
enabled: true
|
|
|
55 |
}
|
|
|
56 |
}
|
|
|
57 |
}
|
|
|
58 |
}
|
|
|
59 |
},
|
|
|
60 |
series: [{
|
|
|
61 |
name: 'USA',
|
|
|
62 |
data: [null, null, null, null, null, 6, 11, 32, 110, 235, 369, 640,
|
|
|
63 |
1005, 1436, 2063, 3057, 4618, 6444, 9822, 15468, 20434, 24126,
|
|
|
64 |
27387, 29459, 31056, 31982, 32040, 31233, 29224, 27342, 26662,
|
|
|
65 |
26956, 27912, 28999, 28965, 27826, 25579, 25722, 24826, 24605,
|
|
|
66 |
24304, 23464, 23708, 24099, 24357, 24237, 24401, 24344, 23586,
|
|
|
67 |
22380, 21004, 17287, 14747, 13076, 12555, 12144, 11009, 10950,
|
|
|
68 |
10871, 10824, 10577, 10527, 10475, 10421, 10358, 10295, 10104]
|
|
|
69 |
}, {
|
|
|
70 |
name: 'USSR/Russia',
|
|
|
71 |
data: [null, null, null, null, null, null, null, null, null, null,
|
|
|
72 |
5, 25, 50, 120, 150, 200, 426, 660, 869, 1060, 1605, 2471, 3322,
|
|
|
73 |
4238, 5221, 6129, 7089, 8339, 9399, 10538, 11643, 13092, 14478,
|
|
|
74 |
15915, 17385, 19055, 21205, 23044, 25393, 27935, 30062, 32049,
|
|
|
75 |
33952, 35804, 37431, 39197, 45000, 43000, 41000, 39000, 37000,
|
|
|
76 |
35000, 33000, 31000, 29000, 27000, 25000, 24000, 23000, 22000,
|
|
|
77 |
21000, 20000, 19000, 18000, 18000, 17000, 16000]
|
|
|
78 |
}]
|
|
|
79 |
});
|
|
|
80 |
});
|
|
|
81 |
</script>
|
|
|
82 |
</head>
|
|
|
83 |
<body>
|
|
|
84 |
<script src="../../js/highcharts.js"></script>
|
|
|
85 |
<script src="../../js/modules/exporting.js"></script>
|
|
|
86 |
|
|
|
87 |
<div id="container" style="min-width: 310px; height: 400px; margin: 0 auto"></div>
|
|
|
88 |
|
|
|
89 |
</body>
|
|
|
90 |
</html>
|