ChartDataSet constructor
ChartDataSet({
- required String label,
- required List<
ChartDataPoint> dataPoints, - required Color color,
Creates a chart data set.
dataPoints should not be empty. If empty, the chart may not render correctly.
Implementation
ChartDataSet({
required this.label,
required this.dataPoints,
required this.color,
}) : assert(
dataPoints.isNotEmpty,
'ChartDataSet must have at least one data point',
);