# Yahoo! UI Library

### charts 3.3.0

Yahoo! UI Library > charts > CartesianSeries
Search:
Filters Show Private Show Protected Show Deprecated

## Class CartesianSeries - extends Base - uses Renderer

Known Subclasses:
  ComboSeries AreaSeries MarkerSeries AreaSplineSeries LineSeries SplineSeries

The CartesianSeries class creates a chart with horizontal and vertical axes.

### Constructor

CartesianSeries `( )`

### Properties

#### _bottomOrigin - `private object`

#### _defaultBorderColors - `protected Array`

Collection of default colors used for marker borders in a series when not specified by user.

#### _defaultFillColors - `protected Array`

Collection of default colors used for marker fills in a series when not specified by user.

#### _defaultLineColors - `protected Array`

Collection of default colors used for lines in a series when not specified by user.

#### _defaultPlaneOffset - `private object`

#### _defaultSliceColors - `protected Array`

Collection of default colors used for area fills, histogram fills and pie fills in a series when not specified by user.

#### _leftOrigin - `private object`

#### _xDisplayName - `private object`

#### _yDisplayName - `private object`

#### GUID - `private object`

#### Properties inherited from Plugin.Host:

`PluginHost`

#### Properties inherited from Attribute:

``

#### Properties inherited from Base:

`name`

#### Properties inherited from Renderer:

`_styles`

### Methods

#### _getDefaultColor

`protected _getDefaultColor ( index , type )`
Parses a color based on a series order and type.

Parameters:
  `index <Number>` Index indicating the series order.
  `type <String>` Indicates which type of object needs the color.

Returns: ``
  String

#### _getDefaultStyles

`protected _getDefaultStyles ( )`
Gets the default value for the `styles` attribute. Overrides base implementation.

Returns: ``
  Object

#### _setCanvas

`protected void _setCanvas ( )`
Creates a `Graphic` instance.

#### _toggleVisible

`protected void _toggleVisible ( )`
Shows/hides contents of the series.

#### _updateAxisData

`private void _updateAxisData ( )`

#### _xAxisChangeHandler

`private void _xAxisChangeHandler ( )`

#### _xDataChangeHandler

`private void _xDataChangeHandler ( )`
(protected)

#### _yAxisChangeHandler

`private void _yAxisChangeHandler ( )`

#### _yDataChangeHandler

`private void _yDataChangeHandler ( )`
(protected)

#### addListeners

`private void addListeners ( )`

#### draw

`protected void draw ( )`
Draws the series.

#### render

`private void render ( )`

#### setAreaData

`protected void setAreaData ( )`
Calculates the coordinates for the series.

#### validate

`private void validate ( )`

#### Methods inherited from EventTarget:

`_getType, _monitor, _parseType, addTarget, after, before, bubble, detach, detachAll, fire, getEvent, getTargets, on, once, parseType, publish, removeTarget, subscribe, unsubscribe, unsubscribeAll`

#### Methods inherited from Attribute:

`_addAttrs, _addLazyAttr, _defAttrChangeFn, _fireAttrChange, _getAttr, _getAttrCfg, _getAttrInitVal, _getAttrs, _getStateVal, _isLazyAttr, _normAttrVals, _protectAttrs, _set, _setAttr, _setAttrs, _setAttrVal, _setStateVal, addAttr, addAttrs, attrAdded, get, getAttrs, modifyAttr, removeAttr, reset, set, setAttrs`

#### Methods inherited from Plugin.Host:

`_destroyPlugins, _initPlugins, hasPlugin, plug, unplug`

#### Methods inherited from Base:

`_aggregateAttrs, _defDestroyFn, _defInitFn, _destroyHierarchy, _filterAttrCfs, _getAttrCfgs, _getClasses, _initHierarchy, _initHierarchyData, _preInitEventCfg, destroy, init, toString`

#### Methods inherited from Renderer:

`_getDefaultStyles, _mergeStyles, _setStyles`

### Events

#### categoryDisplayNameChange

`categoryDisplayNameChange ( event )`
Fires when the value for the configuration attribute 'categoryDisplayName' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### directionChange

`directionChange ( event )`
Fires when the value for the configuration attribute 'direction' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### graphChange

`graphChange ( event )`
Fires when the value for the configuration attribute 'graph' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### graphOrderChange

`graphOrderChange ( event )`
Fires when the value for the configuration attribute 'graphOrder' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### heightChange

`heightChange ( event )`
Fires when the value for the configuration attribute 'height' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### orderChange

`orderChange ( event )`
Fires when the value for the configuration attribute 'order' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### renderedChange

`renderedChange ( event )`
Fires when the value for the configuration attribute 'rendered' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### typeChange

`typeChange ( event )`
Fires when the value for the configuration attribute 'type' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### valueDisplayNameChange

`valueDisplayNameChange ( event )`
Fires when the value for the configuration attribute 'valueDisplayName' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### visibleChange

`visibleChange ( event )`
Fires when the value for the configuration attribute 'visible' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xAxisChange

`xAxisChange ( event )`
Fires when the value for the configuration attribute 'xAxis' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xcoordsChange

`xcoordsChange ( event )`
Fires when the value for the configuration attribute 'xcoords' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xDataChange

`xDataChange ( event )`
Fires when the value for the configuration attribute 'xData' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xDisplayNameChange

`xDisplayNameChange ( event )`
Fires when the value for the configuration attribute 'xDisplayName' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xKeyChange

`xKeyChange ( event )`
Fires when the value for the configuration attribute 'xKey' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xMarkerPlaneChange

`xMarkerPlaneChange ( event )`
Fires when the value for the configuration attribute 'xMarkerPlane' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### xMarkerPlaneOffsetChange

`xMarkerPlaneOffsetChange ( event )`
Fires when the value for the configuration attribute 'xMarkerPlaneOffset' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yAxisChange

`yAxisChange ( event )`
Fires when the value for the configuration attribute 'yAxis' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### ycoordsChange

`ycoordsChange ( event )`
Fires when the value for the configuration attribute 'ycoords' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yDataChange

`yDataChange ( event )`
Fires when the value for the configuration attribute 'yData' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yDisplayNameChange

`yDisplayNameChange ( event )`
Fires when the value for the configuration attribute 'yDisplayName' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yKeyChange

`yKeyChange ( event )`
Fires when the value for the configuration attribute 'yKey' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yMarkerPlaneChange

`yMarkerPlaneChange ( event )`
Fires when the value for the configuration attribute 'yMarkerPlane' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### yMarkerPlaneOffsetChange

`yMarkerPlaneOffsetChange ( event )`
Fires when the value for the configuration attribute 'yMarkerPlaneOffset' is changed. You can listen for the event using the on method if you wish to be notified before the attribute's value has changed, or using the after method if you wish to be notified after the attribute's value has changed.

Parameters:
  `event <Event.Facade>` An Event Facade object with the following attribute specific properties added:
  prevVal
    The value of the attribute, prior to it being set
  newVal
    The value the attribute is to be set to
  attrName
    The name of the attribute being set
  subAttrName
    If setting a property within the attribute's value, the name of the sub-attribute property being set

#### Events inherited from Base:

`destroy, destroyedChange, init, initializedChange,`

#### Events inherited from Renderer:

`graphicChange, stylesChange`

### Configuration Attributes

#### categoryDisplayName `- String`

Name used for for displaying category data

#### direction `- String`

Direction of the series

#### graph `- Graph`

Reference to the `Graph` in which the series is drawn into.

#### graphOrder `- Number`

Order of the instance

#### height `- Number`

Returns the height of the parent graph

#### order `- Number`

Order of this instance of this `type`.

#### rendered `- Boolean`

Indicates whether the Series has been through its initial set up.

#### type `- String`

Read-only attribute indicating the type of series.
Default Value: cartesian

#### valueDisplayName `- String`

Name used for for displaying value data

#### visible `- Boolean`

Indicates whether to show the series
Default Value: true

#### xAxis `- Axis`

Reference to the `Axis` instance used for assigning x-values to the graph.

#### xcoords `- Array`

x coordinates for the series.

#### xData `- Array`

Array of x values for the series.

#### xDisplayName `- String`

Name used for for displaying data related to the x-coordinate.

#### xKey `- String`

Indicates which array to from the hash of value arrays in the x-axis `Axis` instance.

#### xMarkerPlane `- Array`

Collection of area maps along the xAxis. Used to determine mouseover for multiple series.

#### xMarkerPlaneOffset `- Number`

Distance from a data coordinate to the left/right for setting a hotspot.

#### yAxis `- Axis`

Reference to the `Axis` instance used for assigning y-values to the graph.

#### ycoords `- Array`

y coordinates for the series

#### yData `- Array`

Array of y values for the series.

#### yDisplayName `- String`

Name used for for displaying data related to the y-coordinate.

#### yKey `- String`

Indicates which array to from the hash of value arrays in the y-axis `Axis` instance.

#### yMarkerPlane `- Array`

Collection of area maps along the yAxis. Used to determine mouseover for multiple series.

#### yMarkerPlaneOffset `- Number`

Distance from a data coordinate to the top/bottom for setting a hotspot.

#### Configuration attributes inherited from Base:

`destroyed initialized`

#### Configuration attributes inherited from Renderer:

`graphic styles`

Copyright © 2011 Yahoo! Inc. All rights reserved.