You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While surface plots support X, Y, and Z as 2-dimensional arrays, contour traces only support 2-dimensional arrays in the Z index, while X and Y must be 1-dimensional arrays.
Because the contour plot is a 2D representation of a surface plot, we would expect that the same data structure could be used to construct either trace.
A workaround to avoid manipulating the dataset would be to use a surface plot with an isometric projection and position so that only specific axes are visible.
vardata=[{z: [[10,10.625,12.5,15.625,20],[5.625,6.25,8.125,11.25,15.625],[2.5,3.125,5.,8.125,12.5],[0.625,1.25,3.125,6.25,10.625],[0,0.625,2.5,5.625,10]],x: [-9,-6,-5,-3,-1],y: [0,1,4,5,7],type: 'contour'}];varlayout={title: 'Setting the X and Y Coordinates in a Contour Plot'};Plotly.newPlot('myDiv',data,layout);
The text was updated successfully, but these errors were encountered:
While surface plots support X, Y, and Z as 2-dimensional arrays, contour traces only support 2-dimensional arrays in the Z index, while X and Y must be 1-dimensional arrays.
Because the contour plot is a 2D representation of a surface plot, we would expect that the same data structure could be used to construct either trace.
A workaround to avoid manipulating the dataset would be to use a surface plot with an isometric projection and position so that only specific axes are visible.
See these examples for reference:
Surface.js
Contour.js
The text was updated successfully, but these errors were encountered: