-
Notifications
You must be signed in to change notification settings - Fork 22
/
Copy pathchartsScript.php
77 lines (63 loc) · 1.31 KB
/
chartsScript.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<div id="chart-container" style="height: 400px; min-width: 310px; max-width: 600px; margin: 0 auto"></div>
<script>
Highcharts.chart('chart-container', {
chart: {
type: 'bubble',
plotBorderWidth: 1,
zoomType: 'xy'
},
legend: {
enabled: false
},
title: {
text: '<h2> Articles in Chart. </h2>'
},
subtitle: {
text: ' '
},
xAxis: {
gridLineWidth: 1,
type:'datetime',
title: {
text: 'Date'
}
},
yAxis: {
startOnTick: false,
endOnTick: false,
title: {
text: 'Ratings'
},
labels: {
format: '{value}%'
},
maxPadding: 0.2,
},
tooltip: {
useHTML: true,
headerFormat: '<table>',
pointFormat: '<tr>{point.heading}</tr>' +
'<tr><th>Date:</th><td>{point.x:%d.%m.%Y}</td></tr>' +
'<tr><th>Ratings:</th><td>{point.z}%</td></tr>',
footerFormat: '</table>',
followPointer: true
},
plotOptions: {
series: {
cursor: 'pointer',
point: {
events: {
click: function() {
// location.href = this.url;
window.open(this.url, '_blank');
}
}
},
dataLabels: {
enabled: false,
format: '{point.name}'
}
}
},
series: [{
data: [