I have two lines in my charts.js graph. One is in scale from 1-10 and the other is 100 000-1 000 000 000. I would like to have them in one graph, not two, but not to show them in the same time because they are then only one strait line.
Is it possible to show one or the other line in chart configuration? When I turn the first, the second would automatic hide and vice versa. The first picture could confuse a user. I want when loading for a first time, to show like in pic2 or pic3.
This is my chart code:
public barChartOptions: ChartOptions = {
indexAxis: 'x',
responsive: true,
plugins: {}
};
public barChartLabels: string[] = this.xLabels;
public barChartType: ChartType = 'line';
public barChartLegend = true;
public barChartData: ChartDataset[] = [
{
data: [],
backgroundColor: 'green',
borderColor: 'rgb(75, 192, 192)',
label: 'Volume [m3]',
fill: false,
},
{
data: [],
backgroundColor: 'red',
borderColor: 'rgb(255, 127, 127)',
label: 'Flow [m3/h]',
fill: false
}
];


