Protected
_shadingAppend a single XYZ
coordinate or list of coordinates into the series.
// Example, add single data point.
pointSeries.add({ x: 0, y: 0, z: 0 })
// Example, add list of data points.
pointSeries.add([
{ x: 0, y: 100, z: 50 },
{ x: 10, y: 50, z: 150 },
{ x: 20, y: 75, z: 100 },
])
Performance-wise, it is more efficient to call add
just 1 time with an Array of points, instead of calling add
several times with 1 point at a time.
Data points can also be grouped with extra optional properties:
size
| Point size.color
| Point color.value
| Point value for dynamic coloring.setPointStyle method documentation contains detailed information about each of these features and how to use them.
Object itself for fluent interface.
Attach object to an legendBox entry
Object itself for fluent interface
Object which has to be attached
Optional
toggleVisibilityOnClick: booleanFlag that indicates whether the Attachable should be hidden or not, when its respective Entry is clicked.
Clear all previously pushed data points from the series.
// Example usage
pointSeries.clear()
Object itself for fluent interface.
Permanently destroy the component.
To fully allow Garbage-Collection to free the resources used by the component, make sure to remove any references to the component and its children in application code.
let chart = ...ChartXY()
let axisX = chart.getDefaultAxisX()
// Dispose Chart, and remove all references so that they can be garbage-collected.
chart.dispose()
chart = undefined
axisX = undefined
Object itself for fluent interface
Get whether series is taken into account with automatic scrolling and fitting of attached axes.
By default, this is true for all series.
true
default, axes will take series into account in scrolling and fitting operations.
false
, axes will ignore series boundaries.
Get theme effect enabled on component or disabled.
A theme can specify an Effect to add extra visual oomph to chart applications, like Glow effects around data or other components.
Whether this effect is drawn above a particular component can be configured using the setEffect
method.
// Example, disable theme effect from a particular component.
Component.setEffect(false)
For the most part, theme effects are enabled by default on most components.
Theme effect is configured with effect property.
Boolean that describes whether drawing the theme effect is enabled around the component or not.
Get normal points style.
TriangulatedPoints3D
Subscribe onDispose
event.
This event is triggered whenever the ChartComponent is disposed.
// Example usage
lineSeries.onDispose(() => {
console.log('lineSeries was disposed')
})
lineSeries.dispose()
Token of subscription
Event handler function
Subscribe to highlight object event. This is called whenever an object is highlighted.
Token that can be used to unsubscribe from the event.
Function that is called when event is triggered.
Add event listener to Mouse Click Event
Token of the event listener
Event listener for Mouse Click Event
Add event listener to Mouse Double Click Event
Token of the event listener
Event listener for Mouse Double Click Event
Add event listener to Mouse Down Event
Token of the event listener
Event listener for Mouse Down Event
Subscribe to Mouse Drag event
Subscribe to Mouse Drag Start event
Subscribe to Mouse Drag Stop event
Add event listener to Enter Event
Token of the event listener
Event listener for Mouse Enter Event
Add event listener to Mouse Leave Event
Token of the event listener
Event listener for Mouse Leave Event
Add event listener to Mouse Move Event
Token of the event listener
Event listener for Mouse Move Event
Add event listener to Mouse Up Event
Token of the event listener
Event listener for Mouse Up Event
Subscribe to Mouse Wheel event
Token of subscription
Event handler function
Subscribe to Touch End event
Token of subscription
Event handler function
Subscribe to Touch Move event
Token of subscription
Event handler function
Subscribe to Touch Start event
Token of subscription
Event handler function
Register new event listener to visibleStateChanged
event.
Event listener for visibleStateChanged
Set component highlight animations enabled or not. For most components this is enabled by default.
// Example usage, disable highlight animations.
component.setAnimationHighlight(false)
Object itself
Animation enabled?
Set whether series is taken into account with automatic scrolling and fitting of attached axes.
By default, this is true for all series.
By setting this to false
, any series can be removed from axis scrolling/fitting.
// Example syntax, remove series from automatic scrolling / fitting.
LineSeries.setAutoScrollingEnabled(false)
Object itself for fluent interface.
true
default, axes will take series into account in scrolling and fitting operations.
false
, axes will ignore series boundaries.
Set Color Shading Style for series.
Shading style changes the visual style of the rendering. See ColorShadingStyles for available shading styles.
Use Simple color shading style:
series3D.setShadingStyle(new ColorShadingStyles.Simple())
Use Phong color shading style:
series3D.setShadingStyle(new ColorShadingStyles.Phong())
Configuring specular highlight for Phong shading style:
series3D.setShadingStyle(new ColorShadingStyles.Phong({
specularReflection: 0.5,
specularColor: ColorRGBA(255, 255, 255)
}))
Object itself for fluent interface.
Color shading style to use for this series.
Set 3D depth test enabled for this series.
By default this is enabled, meaning that any series that is rendered after this series and is behind this series will not be rendered.
Can be disabled to alter 3D rendering behavior.
// Example syntax, disable depth test.
pointSeries3D.setDepthTestEnabled(false)
Object itself for fluent interface.
Depth test enabled?
Set theme effect enabled on component or disabled.
A theme can specify an Effect to add extra visual oomph to chart applications, like Glow effects around data or other components.
Whether this effect is drawn above a particular component can be configured using the setEffect
method.
// Example, disable theme effect from a particular component.
Component.setEffect(false)
For the most part, theme effects are enabled by default on most components.
Theme effect is configured with effect property.
Object itself.
Theme effect enabled
Set state of component highlighting.
// Example usage
component.setHighlight(true)
component.setHighlight(0.5)
If highlight animations are enabled (which is true by default), the transition will be animated. As long as the component is highlighted, the active highlight intensity will be animated continuously between 0 and the configured value. Highlight animations can be disabled with setAnimationHighlight
Object itself
Boolean or number between 0 and 1, where 1 is fully highlighted.
Set highlight on mouse hover enabled or disabled.
Mouse interactions have to be enabled on the component for this to function as expected. See setMouseInteractions for more information.
Object itself for fluent interface.
True if highlighting on mouse hover, false if no highlight on mouse hover
Set component mouse interactions enabled or disabled.
Disabling mouse interactions means that the objects below this component can be interacted through it.
Possible side-effects from disabling mouse interactions:
Object itself for fluent interface
Specifies state of mouse interactions
Sets the name of the Component updating attached LegendBox entries
Object itself
Name of the Component
Set point style of Series.
Example syntax:
// Example syntax, Specify new style
pointSeries3D.setPointStyle( new PointStyle3D.Triangulated({
size: 10,
shape: 'sphere',
fillStyle: new SolidFill({ color: ColorHEX('#FFF') })
}) )
// Example syntax, Change point color
pointSeries3D.setPointStyle( (pointStyle) => pointStyle
.setFillStyle( new SolidFill({ color: ColorHEX('#FFF') }) )
)
// Example syntax, Change point size
pointSeries3D.setPointStyle( (pointStyle) => pointStyle
.setSize( 10 )
)
// Example syntax, Change point shape
pointSeries3D.setPointStyle( (pointStyle) => pointStyle
.setShape( 'cube' )
)
Point coloring:
Color of points is configured by the fillStyle
property of active point style.
Here is a list of all supported fill styles with feature descriptions and example syntax:
Solid color for all points in series.
// Example syntax, solid points color.
pointSeries3D.setPointStyle(new PointStyle3D.Triangulated({
fillStyle: new SolidFill({ color: ColorRGBA(255, 0, 0) }),
size: 10,
shape: 'sphere'
}))
Look-up dynamic per-point color based on a look up property (number) and a color look up table (LUT).
// Example syntax, dynamic points color.
pointSeries3D.setPointStyle(new PointStyle3D.Triangulated({
fillStyle: new PalettedFill({
// lookUpProperty defines basis of selecting look up value (number).
lookUpProperty: 'value',
// lut defines table for mapping look up value (number) to a color.
lut: new LUT({
interpolate: true,
steps: [
{ value: 0, color: ColorRGBA(0, 0, 0) },
{ value: 1, color: ColorRGBA(255, 0, 0) }
]
})
}),
size: 10,
shape: 'sphere'
}))
PointSeries3D
supports several different look-up modes:
lookUpProperty: 'value'
:
IMPORTANT: In order to use value
property on data points, the feature has to be explicitly activated when the series is created:
// Example syntax, enable individual data point values.
const pointSeries3D = chart3D.addPointSeries({
individualLookupValuesEnabled: true
})
value
property is then added for every data point along side x
, y
and z
:
// Example syntax, individual data point values.
pointSeries3D.add([
{ x: 0, y: 0, z: 0, value: 0 },
{ x: 1, y: 0, z: 2, value: 1 },
])
Look-up value is read from data point value
property.
lookUpProperty: 'x'
:
Look-up value is set to data point x
coordinate on Axis.
lookUpProperty: 'y'
:
Look-up value is set to data point y
coordinate on Axis.
lookUpProperty: 'z'
:
Look-up value is set to data point z
coordinate on Axis.
Supply individual color for each data point.
IMPORTANT: In order to use IndividualPointFill
, the feature has to be explicitly activated when the series is created:
// Example syntax, enable individual data point colors.
const pointSeries3D = chart3D.addPointSeries({
individualPointColorEnabled: true
})
color
property is then added for every data point along side x
, y
and z
:
// Example syntax, individual data point colors.
pointSeries3D.add([
{ x: 0, y: 0, z: 0, color: ColorRGBA(255, 0, 0) },
{ x: 1, y: 0, z: 2, color: ColorRGBA(0, 255, 0) },
])
Point size:
Size of points is configured by the size
property of active point style.
If required, points can also be individually sized by adding a size
property to data points.
IMPORTANT: In order to use size
property, the feature has to be explicitly activated when the series is created:
// Example syntax, enable individual data point size.
const pointSeries3D = chart3D.addPointSeries({
individualPointSizeEnabled: true
})
size
property is then added for every data point along side x
, y
and z
:
// Example syntax, individual data point sizes.
pointSeries3D.add([
{ x: 0, y: 0, z: 0, size: 5 },
{ x: 1, y: 0, z: 2, size: 10 },
])
Point size 3D:
As an alternative method to size
, each 3D point can also be sized with individual sizes for each Axis (X, Y and Z).
This is done by adding sizeAxisX
, sizeAxisY
, and sizeAxisZ
properties to data points.
IMPORTANT: In order to use these properties, the feature has to be explicitly activated when the series is created:
// Example syntax, enable individual data point 3D axis size.
const pointSeries3D = chart3D.addPointSeries({
individualPointSizeAxisEnabled: true
})
sizeAxisX
, sizeAxisY
and sizeAxisZ
properties are then added for every data point along side x
, y
and z
:
// Example syntax, individual data point 3D axis sizes.
pointSeries3D.add([
{ x: 0, y: 0, z: 0, sizeAxisX: 1, sizeAxisY: 10, sizeAxisZ: 5 },
{ x: 1, y: 0, z: 2, sizeAxisX: 1, sizeAxisY: 10, sizeAxisZ: 5 },
])
IMPORTANT: in order for points to be sized based on sizeAxisX
, sizeAxisY
and sizeAxisZ
properties, the active point style must also have a fallback point size definition as axis dimensions:
pointSeries3D.setPointStyle(new PointStyle3D.Triangulated({
// IMPORTANT: fallback `size` must be defined with { x, y, z } syntax!
size: { x: 1, y: 1, z: 1 },
shape: 'sphere',
fillStyle: new SolidFill({ color: ColorRGBA(255, 0, 0) })
}))
Object itself for fluent interface
A TriangulatedPoints3D object, or a function which modifies the current style.
Set element visibility.
Object itself.
true
when element should be visible and false
when element should be hidden.
Series type for visualizing a collection of
{ x, y, z }
coordinates by different markersPointSeries3D
is optimized for massive amounts of data - here are some reference specs to give an idea:Creating PointSeries3D:
PointSeries3D
are created with addPointSeries method.Some properties of
PointSeries3D
can only be configured when it is created. These arguments are all optional, and are wrapped in a single object parameter:To learn about available properties, refer to PointSeriesOptions3D.
Frequently used methods:
Color shading style.
By default,
PointSeries3D
uses Phong shading style.This can be changed with
PointSeries3D.setColorShadingStyle(new ColorShadingStyles.Simple())
Related information:
There is another series type for visualizing large sets of 3D coordinates with markers: PointCloudSeries3D
PointCloudSeries3D
works otherwise same, except that it has simplified render process (all markers are 2D geometry), which is faster and can be really powerful in visualizing large low-detail data sets!