Credits Overview Plotting Styles Commands Terminals

contourfill

figure_contourfill

Syntax:

     splot f(x,y) with contourfill {at base} {fillstyle <style>}

Contourfill is a 3D plotting style used to color a pm3d surface in slices along the z axis. It can be used in 2D projection (set view map or with contourfill at base) to create 2D contour plots with solid color between contour lines. The slice boundaries and the assigned colors are both controlled using set contourfill. See also pm3d, zclip.

The default fill properties are taken from set pm3d but may be modified by providing a different fillstyle in the splot command.

This style can be combined with set contours to superimpose contour lines that bound the slices. Care must be taken that the slice boundaries from set contourfill match the contour bounaries from set cntrparam.

     # slice boundaries determined by ztics
     # coloring set by palette mapping the slice midpoint z value
     set pm3d border retrace
     set contourfill ztics
     set ztics -20, 5, 20
     set contour
     set cntrparam cubic levels increment -20, 5, 20
     set cntrlabel onecolor
     set view map
     splot g(x,y) with contourfill, g(x,y) with lines nosurface

By default the contours are rendered onto the original 3D surface. Plotting with contourfill at base instead projects the colored surface onto the base plane. To draw both a surface and its projected contour coloring

     set hidden3d front
     splot f(x,y) using lines, f(x,y) using contourfill at base