Не получается настроить chart.js
Необходимо настроить диаграмму по следующему типу:
Лучшее, что вышло у меня это:
Мой код
var ctx = document.getElementById("myChart");
var myChart = new Chart(ctx, {
type: 'line',
data: {
datasets: [{
data: [{
x: -2,
y: 26
}, {
x: -1,
y: 16
}, {
x: 0,
y: 16
}, {
x: 1,
y: 26
}, {
x: 2,
y: 46
}],
borderColor: [
'rgba(33, 232, 234, 1)'
],
borderWidth: 1
}],
},
options: {
legend: {
display: false
},
scales: {
xAxes: [{
type: 'linear',
position: 'bottom',
ticks: {
min: -10,
max: 10,
stepSize: 5,
}
}],
yAxes: [{
ticks: {
stepSize: 100,
}
}]
}
}
});