Class: Langevitour

Langevitour(container, width, height)

Class to create and animate a Langevin Tour widget

Constructor

new Langevitour(container, width, height)

Create a Langevin Tour widget.
Parameters:
Name Type Description
container HTMLElement Element to insert widget into.
width number Desired initial width of widget.
height number Desired initial height of widget.
Source:

Methods

getState()

Get the current widget state.
Source:

renderValue(data)

Show data in the widget.
Parameters:
Name Type Description
data object The data to show.
Properties
Name Type Attributes Description
X Array.<Array.<number>> A row-major matrix, where each row represents a point and each column represents a variable. The data should be centered and scaled.
scale Array.<scale> Scaling to restore original units of X.
center Array.<number> Center to restore original units of X.
colnames Array.<string> A name for each column in X.
rownames Array.<string> <optional>
A name for each point.
group Array.<number> <optional>
Group number for each point. Integer values starting from 0.
levels Array.<string> <optional>
Group names for each group in data.group.
extraAxes Array.<Array.<number>> <optional>
A matrix with each column defining a projection of interest.
extraAxesCenter Array.<number> <optional>
Center to restore original units of extra axes. Scaling is assumed already included in data.extraAxes.
extraAxesNames Array.<string> <optional>
A name for each extra axis.
lineFrom Array.<number> <optional>
Rows of X to draw lines from.
lineTo Array.<number> <optional>
Rows of X to draw lines to.
axisColors Array.<string> <optional>
CSS colors for each variable and then optionally for each extra axis.
levelColors Array.<string> <optional>
CSS colors for each level.
colorVariation number <optional>
Amount of brightness variation of points, between 0 and 1.
pointSize number <optional>
Radius of points in pixels.
Source:

resize(width, height)

Resize the widget. Ignored if widget has gone full-screen.
Parameters:
Name Type Description
width number New width.
height number New height.
Source:

setState(state)

Set the widget state. Can be used to restore a previous state of the widget obtained with getState().
Parameters:
Name Type Description
state A JSON string or an Object containing the desired state.
Source: