Package muntjac :: Package addon :: Package invient :: Module invient_charts :: Class XYSeries
[hide private]
[frames] | no frames]

Class XYSeries

source code

object --+    
         |    
    Series --+
             |
            XYSeries

This class defines a number series. In this series both X and Y values must be number. To use date values, use DateTimeSeries


Authors:
Invient, Richard Lincoln

See Also: DateTimeSeries

Instance Methods [hide private]
 
__init__(self, name, seriesType_or_config=None, config=None)
Creates a series with given name, type and configuration
source code
 
removePoint(self, *points)
Removes the specified point from the series
source code
 
removeAllPoints(self)
Removes all points in this series
source code
 
addPoint(self, point_or_points, shift=None)
Appends the specified point(s) into the series if they do not exists in this series.
source code
 
getPoints(self)
Returns: Returns all points of this series.
source code
 
setSeriesPoints(self, points)
Sets points into this series.
source code
 
updatePointXValuesIfNotPresent(self)
Each of the subclass needs to implement this method to ensure that each point has appropriate X value even if it is not specified.
source code

Inherited from Series: __eq__, __hash__, __str__, addPointsInternal, getConfig, getName, getStack, getType, getXAxis, getYAxis, hide, setInvientCharts, setName, setPoints, setStack, setType, setXAxis, setYAxis, show

Inherited from object: __delattr__, __format__, __getattribute__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, name, seriesType_or_config=None, config=None)
(Constructor)

source code 

Creates a series with given name, type and configuration

Parameters:
  • name - the name of this series
  • seriesType_or_config - the type of this series or the configuration for this series
  • config - the configuration for this series
Overrides: object.__init__

removePoint(self, *points)

source code 

Removes the specified point from the series

Overrides: Series.removePoint

removeAllPoints(self)

source code 

Removes all points in this series

Overrides: Series.removeAllPoints
(inherited documentation)

addPoint(self, point_or_points, shift=None)

source code 

Appends the specified point(s) into the series if they do not exists in this series. The points which already exists will not be appended. A collection of points appended to this series will be returned.

Parameters:
  • point_or_points
  • shift - If true then one point is shifted off the start of this series as one is appended to the end.
Returns:
Returns a collection of points which are added in this series. If a point has same (x, y) value as any other point in the input argument points then it will not be added in this series.
Overrides: Series.addPoint

getPoints(self)

source code 
Returns:
Returns all points of this series. Adding or removing any point to or from the returned collection will not impact the chart. To add a point or points, use addPoint() or removePoint() method.
Overrides: Series.getPoints
(inherited documentation)

setSeriesPoints(self, points)

source code 

Sets points into this series. This method removes all of its points and then add points specified in the method argument. If the argument is null then no actions are taken.

Parameters:
  • points - the collection of points to set into this series.
Returns:
Returns a collection of points which are set in this series. If a point has same (x, y) value as any other point in the argument points then it will not be added.

updatePointXValuesIfNotPresent(self)

source code 

Each of the subclass needs to implement this method to ensure that each point has appropriate X value even if it is not specified.

Overrides: Series.updatePointXValuesIfNotPresent
(inherited documentation)