Demonstrates how to create a JavaScript Chart with multiple X,Y axis using SciChart.js, High Performance JavaScript Charts
This example demonstrates how to create a high-performance chart with multiple X and Y axes using JavaScript and SciChart.js. Its purpose is to showcase the configuration of two independent pairs of numeric axes along with binding data series via unique axis IDs, while integrating interactive modifiers and custom annotations for an enhanced user experience.
The implementation begins by initializing a SciChartSurface with a custom theme. Two sets of NumericAxis are added: the primary (blue) set aligned using axis.alignment = EAxisAlignment.Bottom and EAxisAlignment.Left, and the secondary (orange) set aligned to the EAxisAlignment.Top and EAxisAlignment.Right. Data is generated through a random walk generator, and each data series is bound to its corresponding axis by setting a unique on axis.id. Series can then be registered on a specific axis by setting FastLineRenderableSeries.xAxisId and yAxisId. Interactive modifiers, including YAxisDragModifier, XAxisDragModifier as well as zoom, pan, mouse-wheel zoom and zoom-extents are then added. Developers seeking further details on multi-axis configuration may refer to the Tutorial 08 - Adding Multiple Axis and for interactivity see the Tutorial 03 - Adding Zooming, Panning Behavior.
The chart offers several advanced features:
axis.alignment, axis.axisBorder, and background styling via axis.backgroundColor, providing distinct visual themes. More details can be found in the Axis Styling docs.XAxisDragModifier, YAxisDragModifier, ZoomPanModifier, and MouseWheelZoomModifier enable dynamic interaction, helping users adjust the view in real time.Although this example is implemented using JavaScript, it illustrates best practices for resource cleanup and the management of the SciChartSurface lifecycle, as outlined in the Memory Best Practices guide. Even though a React component wrapper is provided for integration into larger applications, the core functionality relies solely on JavaScript, making it adaptable across various frameworks. This approach ensures that developers can easily integrate and expand upon the chart in different environments without the overhead of additional abstraction layers.

Demonstrates Secondary Y Axis on a JavaScript Chart using SciChart.js. SciChart supports unlimited, multiple left, right, top, bottom X, Y axis with configurable alignment and individual zooming, panning

Demonstrates alignment of Axis to create a vertical chart with SciChart.js - JavaScript Charts.

Demonstrates Central Axes on a JavaScript Chart using SciChart.js. SciChart supports unlimited left, right, top, bottom X, Y axis with configurable layout

Demonstrates isStaticAxis on a JavaScript Chart using SciChart.js.

Demonstrates Vertically Stacked Axes on a JavaScript Chart using SciChart.js, allowing data to overlap

Demonstrates Logarithmic Axis on a JavaScript Chart using SciChart.js. SciChart supports logarithmic axis with scientific or engineering notation and positive and negative values


Demonstrates BaseValue Axes on a JavaScript Chart using SciChart.js to create non-linear and custom-scaled axes such as log-like scales

Demonstrates the option of the transparent Axes customization on a JavaScript Chart using SciChart.js.

Demonstrates how to use arbitrary text for axis labels, rather than formatted data values, using the new TextLabelProvider

Demonstrates outer, inner, central and stacked axes, and use of axis alignment to create vertical charts