Class: Series

Series

Base abstract class to define a series of data

Constructor

new Series(o)

Parameters:
Name Type Description
o Object | Tee.Chart | Array.<Number> An array of numbers, or a chart or datasource object.
Properties:
Name Type Attributes Default Description
chart Tee.Chart The parent chart this Series object belongs to.
data.values Array.<Number> Array of numbers as main series data.
data.labels Array.<String> Array of strings used to display at axis labels, legend and marks.
format Tee.Format Visual properties to display series data.
visible Boolean <optional>
true Determines if this series will be displayed or not.
cursor String <optional>
"default" Defines the mouse cursor to show when mouse is over a series point.
data Object Contains all series data values, labels, etc.
marks Tee.Series.Marks Displays annotations near series points.
colorEach Boolean <optional>
"auto" Paints points using series fill color, or each point with a different color from series palette or chart palette color array.
horizAxis String <optional>
"bottom" Defines the horizontal axis associated with this series.
vertAxis String <optional>
"left" Defines the horizontal axis associated with this series.
Source:

Classes

Marks

Members

legendText

Source:

Methods

associatedToAxis() → {Boolean}

Source:
Returns:
Returns if series is associated to axis, either horizontal or vertical.
Type
Boolean

count() → {Number}

Source:
Returns:
Returns the number of series data values.
Type
Number

dataText(index, style) → {String}

Parameters:
Name Type Description
index Number The point position in series data array.
style String Defines how text is returned: "auto", "value", "percent", "percentlabel", "valuelabel", "label", "index", "labelvalue", "labelpercent"
Source:
Returns:
Returns the text string to show for a given series point index.
Type
String

doSort() → {Array}

Source:
Returns:
Returns an array of series data indices sorted according to sortBy parameter.
Type
Array

getFill() → {String}

Source:
Returns:
Returns the color of index point in series, using series palette or chart palette.
Type
String

getFillStyle() → {CanvasGradient}

Source:
Returns:
Returns a canvas gradient using color, or color if gradient is not visible.
Type
CanvasGradient

isNull() → {boolean}

Source:
Returns:
Returns true when the index'th series value is null and should not be painted.
Type
boolean

legendColor() → {Color}

Source:
Returns:
Returns the color of index'th legend symbol.
Type
Color

legendCount() → {Number}

Source:
Returns:
Returns the number of items to show at legend.
Type
Number

markText() → {String}

Source:
Returns:
Returns the text string to show at series marks, for a given series point index.
Type
String

maxXValue() → {Number}

Source:
Returns:
Returns the maximum value of series x values, or data length minus one, if no x values exist.
Type
Number

maxYValue() → {Number}

Source:
Returns:
Returns the maximum value of series values, or zero if no values exist.
Type
Number

minXValue() → {Number}

Source:
Returns:
Returns the minimum value of series x values, or zero if no x values exist.
Type
Number

minYValue() → {Number}

Source:
Returns:
Returns the minimum value of series data values, or zero if no values exist.
Type
Number

pointOrigin() → {Number}

Source:
Returns:
Returns the sum of all previous visible series index'th value, for stacking.
Type
Number

stackMaxValue() → {Number}

Source:
Returns:
Returns the maximum of all series values, or sum of all stacked values.
Type
Number

toPercent() → {String}

Source:
Returns:
Returns a percentual representation of the series index'th value, on total of series values.
Type
String

valueOrLabel() → {String}

Source:
Returns:
Returns the series index'th data label, or the value if no label exists at that index.
Type
String

valueText() → {String}

Source:
Returns:
Returns the text string for a given series point index value.
Type
String