TrendLine
Type class
Creates a trendline for AmSerialChart and AmXYChart charts which indicates the trend of your data or covers some different purposes. Multiple can be assigned.
Example
```js var chart = AmCharts.makeChart("chartdiv",{ ... "trendLines": [ { "initialValue": 1, "initialXValue": 1, "finalValue": 11, "finalXValue": 12 } ] });```Sources
This information about TrendLine is provided for reference only and is not available through exported packages and thus should not be imported or used on its own.
Inheritance
TrendLine does not extend any other symbol.
TrendLine is not extended by any other symbol.
Properties
balloonTextType
stringWhen set, enables displaying a roll-over balloon.
dashLengthType
numberDefault0Dash length.
finalCategoryType
stringString, equal to category value to which trend line should be drawn. It should be used if chart doesn't parse dates.
finalDateType
dateDate to which trend line should be drawn. It can be date string (using the same date format as chart.dataDateFormat) or date object.
finalImageType
ImageAllows to add an image to the end of a trend line.
finalValueType
numberValue at which trend line should end.
finalXValueType
numberUsed by XY chart only. X value at which trend line should end.
idType
stringUnique id of a Trend line. You don't need to set it, unless you want to.
initialCategoryType
stringString, equal to category value from which trend line should start. It should be used if chart doesn't parse dates.
initialDateType
dateDate from which trend line should start. It can be date string (using the same date format as chart.dataDateFormat) or date object.
initialImageType
ImageAllows to add an image to the beginning of a trend line.
initialValueType
numberValue from which trend line should start.
initialXValueType
numberUsed by XY chart only. X value from which trend line should start.
isProtectedType
booleanDefaultfalseUsed by Stock chart. If this property is set to true, this trend line won't be removed when clicked on eraser tool.
lineAlphaType
numberDefault1Line opacity.
lineColorType
colorDefault#00CC00Line color.
lineThicknessType
numberDefault1Line thickness.
Methods
TrendLine does not have any methods.
Events
clickParam { type:
"click", target:TrendLine} &{type: "click", TrendLine, chart:AmRectangularChart}Dispatched when user clicks on a trend line.
rollOutParam { type:
"rollOut", target:TrendLine} &{type: "rollOut", TrendLine, chart:AmRectangularChart}Dispatched when user rolls out of a trend line.
rollOverParam { type:
"rollOver", target:TrendLine} &{type: "rollOver", TrendLine, chart:AmRectangularChart}Dispatched when user clicks rolls-over a trend line.