Chartjs-ChartJS โ€“ Line Chart โ€“ Tracking correlation between multiple datasets with large range in values

0๐Ÿ‘

i think if you want to create a single chart with 3 different lines, you have to make the data in one dataset. sorry im not good in explaining things but you can checked code below.

const data = {
  label: 'Multi Line',
  dataset: [
            {label: 'Average Purchase Value',
             data: [25, 28, 24, 26]}, 
            {label: 'Session Duration',
             data: [80, 120, 90, 85]},
            {label: 'Average Items Purchased',
             data: [3, 2, 1, 1]},
           ]
}

hope it can help you

0๐Ÿ‘

Ended up using the Multi-axis feature of ChartJS

https://www.chartjs.org/docs/latest/samples/line/multi-axis.html

Leave a comment