ValueFormatterFunc typedef

ValueFormatterFunc = dynamic Function(num numOrMillis, dynamic opts, String? seriesName, Dygraph? dygraph, num row, num col)

Implementation

typedef ValueFormatterFunc = dynamic Function(
  // The value to be formatted. This is always a number. For date axes, it's millis since epoch.
  num numOrMillis,
  // This is a function you can call to access various options (e.g. opts('labelsKMB')).
  // It returns per-axis values for the option when available.
  dynamic opts,
  // The name of the series from which the point came, e.g. 'X', 'Y', 'A', etc.
  String? seriesName,
  // The dygraph object for which the formatting is being done
  Dygraph? dygraph,
  // The row of the data from which this point comes. g.getValue(row, 0) will return the x-value for this point.
  num row,
  // The column of the data from which this point comes. g.getValue(row, col) will return the original y-value for this point.
  // This can be used to get the full confidence interval for the point, or access un-rolled values for the point.
  num col,
);