A surface chart visualizes continuous data as a 3D mesh, mapping two variables to height and color across a smooth surface. It is well suited for mathematical functions and scientific datasets that span two dimensions.
This sample renders the peaks function, a combination of translated and scaled Gaussian distributions frequently used to demonstrate 3D plotting. The Math.js library evaluates the expression across a grid, and the resulting values feed directly into the surface mesh. Custom rotation angles, formatted axis labels with two decimal places, and styled grid strokes let you examine the peaks and valleys from multiple perspectives.
See the Surface Chart documentation for all configuration options, or explore this chart type in Chartopedia.