Stepfunction

Element

A step function is a function graph that is piecewise constant.

In case the data points should be updated after creation time, they can be accessed by curve.xterm and curve.yterm.

Usage (signatures)
board.create('stepfunction', [Parent1, Parent2]);
Parameters
Name Type Description
Parent1 Array | function

Array of x-coordinates, or function returning such an array

Parent2 Array | function

Array of y-coordinates, or function returning such an array

Example
// Create step function.
var curve = board.create('stepfunction', [[0,1,2,3,4,5], [1,3,0,2,2,1]]);
Attributes

Own

none

Inherited

Members

Own

none

Inherited

Methods

Own

none

Inherited

Events

Own

none

Inherited

Details

Type
JXG.Curve
Source
base/curve.js, line 2736

Extends