Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
62 lines (50 sloc) 1.41 KB
<script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/highcharts-more.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="min-width: 400px; max-width: 600px; height: 400px; margin: 0 auto"></div>
<script>
Highcharts.chart('container', {
chart: {
polar: true,
type: 'line'
},
title: {
text: '一ヶ月の僕の収支',
x: -80
},
pane: {
size: '80%'
},
xAxis: {
categories: ['今月お小遣い', '昼食代', 'パチンコ代', 'デート代',
'交通費', 'スマホ代'],
tickmarkPlacement: 'on',
lineWidth: 0
},
yAxis: {
gridLineInterpolation: 'polygon',
lineWidth: 0,
min: 0
},
tooltip: {
shared: true,
pointFormat: '<span style="color:{series.color}">{series.name}: <b>${point.y:,.0f}</b><br/>'
},
legend: {
align: 'right',
verticalAlign: 'top',
y: 70,
layout: 'vertical'
},
series: [{
name: '',
data: [10000, 30000, 50000, 0, 5000, 5000],
pointPlacement: 'on'
}, {
name: '普通の人',
data: [100000, 15000, 0, 60000, 10000, 15000],
pointPlacement: 'on'
}]
});
</script>