-
Notifications
You must be signed in to change notification settings - Fork 0
/
andym-Graph.html
101 lines (94 loc) · 2.08 KB
/
andym-Graph.html
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<!DOCTYPE HTML>
<html>
<head>
<script type="text/javascript" src="andym-GraphData.js"></script>
<link href="rebuystyles.css" rel="stylesheet" type="text/css">
<script>
window.onload = function () {
var chart = new CanvasJS.Chart("chartContainer", {
axisX:{
labelAngle: 45
},
axisY:[
{
title: "Statistics",
includeZero: true,
lineColor: "DarkRed",
tickColor: "DarkRed",
labelFontColor: "DarkRed",
titleFontColor: "DarkRed",
suffix: "%"
}],
axisY2: {
title: "Won/Lost",
includeZero: true,
lineColor: "DarkGreen",
tickColor: "DarkGreen",
labelFontColor: "DarkGreen",
titleFontColor: "DarkGreen",
prefix: "$",
},
toolTip: {
shared: true
},
legend: {
cursor: "pointer",
itemclick: toggleDataSeries
},
data: [
{
type: "line",
name: "PFR",
color: "DarkRed",
markerType: "square",
axisYIndex: 0,
showInLegend: true,
},
{
type: "line",
name: "VPIP",
color: "DarkRed",
markerType: "triangle",
axisYIndex: 0,
showInLegend: true,
},
{
type: "line",
name: "Agg Factor",
color: "DarkRed",
markerType: "circle",
axisYIndex: 0,
showInLegend: true,
},
{
type: "line",
name: "Won/Lost",
color: "DarkGreen",
axisYType: "secondary",
showInLegend: true,
}]
});
chart.options.data[0].dataPoints = PFR;
chart.options.data[1].dataPoints = VPIP;
chart.options.data[2].dataPoints = Agg;
chart.options.data[3].dataPoints = wonLost;
chart.render();
function toggleDataSeries(e) {
if (typeof (e.dataSeries.visible) === "undefined" || e.dataSeries.visible) {
e.dataSeries.visible = false;
} else {
e.dataSeries.visible = true;
}
e.chart.render();
}
}
</script>
</head>
<body>
<div class="grid-header" style="width:100%;">
<label id="titleTab" style="font-size: 16px;">andy m Statistics across Sessions</label>
</div>
<div id="chartContainer" style="height: 370px; width: 100%;"></div>
<script src="https://canvasjs.com/assets/script/canvasjs.min.js"></script>
</body>
</html>