MacdIndicator<T, D> constructor
MacdIndicator<T, D> ({
- bool isVisible = true,
- String? xAxisName,
- String? yAxisName,
- String? seriesName,
- List<
double> dashArray = const <double>[0, 0], - double animationDuration = 1500,
- double animationDelay = 0,
- List<
T> ? dataSource, - ChartValueMapper<
T, D> ? xValueMapper, - ChartValueMapper<
T, num> ? closeValueMapper, - String? name,
- bool isVisibleInLegend = true,
- LegendIconType legendIconType = LegendIconType.seriesType,
- String? legendItemText,
- Color signalLineColor = Colors.blue,
- double signalLineWidth = 2,
- int period = 14,
- int shortPeriod = 12,
- int longPeriod = 26,
- Color macdLineColor = Colors.orange,
- double macdLineWidth = 2,
- MacdType macdType = MacdType.both,
- Color histogramPositiveColor = Colors.green,
- Color histogramNegativeColor = Colors.red,
- ChartIndicatorRenderCallback? onRenderDetailsUpdate,
Creating an argument constructor of MacdIndicator class.
Implementation
MacdIndicator({
super.isVisible,
super.xAxisName,
super.yAxisName,
super.seriesName,
super.dashArray,
super.animationDuration,
super.animationDelay,
super.dataSource,
ChartValueMapper<T, D>? xValueMapper,
ChartValueMapper<T, num>? closeValueMapper,
super.name,
super.isVisibleInLegend,
super.legendIconType,
super.legendItemText,
super.signalLineColor,
super.signalLineWidth,
this.period = 14,
this.shortPeriod = 12,
this.longPeriod = 26,
this.macdLineColor = Colors.orange,
this.macdLineWidth = 2,
this.macdType = MacdType.both,
this.histogramPositiveColor = Colors.green,
this.histogramNegativeColor = Colors.red,
super.onRenderDetailsUpdate,
}) : super(
xValueMapper: xValueMapper != null && dataSource != null
? (int index) => xValueMapper(dataSource[index], index)
: null,
closeValueMapper: closeValueMapper != null && dataSource != null
? (int index) => closeValueMapper(dataSource[index], index)
: null,
);