javascript - Is it possible to make chartjs charts scrollable? -
I am trying to create charts for my analytics data using chart.js This is one.
Presently it is with the default sample data. What I want to do is something like, infinite scrolling from left to right:
How can I apply?
Var randomScalingFactor = function () {return Math.round (Math.random () * 100)}; On lineChartData = {label: ["January", "February", "March", "April", "May", "June", "July"], Dataset: [{Label: "My First Dataset", fillColor: "Rgba (220,220,220,0k2)", Strokekolor: "Rgba (220,220,220,l)", Pointsolor: "Rgba (220,220,220,l)", Pointstrokekolor: "#fff" Pointःiligtfill: "#fff" Pointःiligtstroke: "Rgba ( 220,220,220,l) ", data: [randomScalingFactor (), randomScalingFactor (), randomScalingFactor (), randomScalingFactor (), randomScalingFactor (), randomScalingFactor (), randomScalingFactor ()]}, {label:" My second dataset ", FillColor: "Rgba (L5l,l87,205,0k2)", Strokekolor: "Rgba (L5l,l87,205,l)", Pointsolor: "Rgba (L5l,l87,205,l)", Pointstrokekolor: "#fff" Pointःiligtfill: "#fff" Pointःiligtstroke: "Rgba ( 151,187,205,1) ", data: [randomScalingFactor (), randomScalingFactor (), rand omScalingFactor (), randomScalingFactor (), randomScalingFactor (), randomScalingFactor (), RandomScalingFactor ()]}]}} ctx = document.getElementById ( "canvas"). GetContext ("2D"); Window.myLine = New Chart (CTX). LAN (lineartart, {liability: true});
came with its official plugin on
Comments
Post a Comment