convertFromDateMaps static method

Pair<List<ChartLine>, Dates> convertFromDateMaps(
  1. List<Map<DateTime, double>> series,
  2. List<Color> colors,
  3. List<String> units
)

Implementation

static Pair<List<ChartLine>, Dates> convertFromDateMaps(
    List<Map<DateTime, double>> series,
    List<Color> colors,
    List<String> units) {
  Dates minMax = _findMinMax(series);

  int index = 0;
  List<ChartLine> lines = series
      .map((map) => _convert(map, minMax, colors[index], units[index++]))
      .toList();

  return Pair(lines, minMax);
}