Closed
Description
Sometimes 3d data, like simplicial-complex, has TypedArray format, eg. Float32Array for positions and Uint32Array for cell indices:
// positions = Float32Array
// cells = Uint32Array
Plotly.plot(document.body, [{
"x": positions.filter((p, i) => !(i % 3)),
"y": positions.filter((p, i) => !((i-1) % 3)),
"z": positions.filter((p, i) => !((i-2) % 3)),
"i": indices.filter((p, i) => !(i % 3)),
"j": indices.filter((p, i) => !((i-1) % 3)),
"k": indices.filter((p, i) => !((i-2) % 3)),
}])
Would be nice for plotly to be able to deal with TypedArrays and not force users cast data to exact datatype.
Metadata
Metadata
Assignees
Labels
No labels