Series

Instances of BaseSeries performs these tasks:

  1. stores the symbolic expressions and ranges.

  2. stores rendering-related attributes.

  3. create a numerical function of the symbolic expressions using lambdify.

  4. when requested, evaluate the numerical function and return the data.

Backends will request numerical data from each data series and will render them according to the values stored in their attributes.

The best way to instantiate a specific data series is to call one of the functions from The Graphics Module.

The following list shows the public methods/attributes.

class spb.series.BaseSeries(*args, **kwargs)[source]

Base class for the data objects containing stuff to be plotted.

Notes

The backend should check if it supports the data series that it’s given. It’s the backend responsibility to know how to use the data series that it’s given.

spb.series.BaseSeries.get_data(self)

Compute and returns the numerical data.

The number of arrays returned by this method depends on the specific instance. Let s be an instance of BaseSeries. Make sure to read help(s.get_data) to understand what it returns.

BaseSeries.params

Get or set the current parameters dictionary.

Parameters:
pdict
  • key: symbol associated to the parameter

  • val: the numeric value