This is documentation for Mathematica 5, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

Documentation / Mathematica / Built-in Functions / Graphics and Sound / Advanced Options /

ColorFunction

FilledSmallSquare ColorFunction is an option for various graphics functions which specifies a function to apply to values to determine the color to use for a particular , region.

FilledSmallSquare ColorFunction is an option for Plot3D, ListPlot3D, DensityPlot, ContourPlot, Raster and related functions.

FilledSmallSquare With the default setting ColorFunctionScaling -> True, the arguments provided for the function specified by ColorFunction are always scaled to be in the range 0 to 1.

FilledSmallSquare With ColorFunctionScaling -> False original unscaled values are used.

FilledSmallSquare The function specified by ColorFunction must return a CMYKColor, GrayLevel, Hue or RGBColor directive.

FilledSmallSquare ColorFunction -> Automatic yields a range of gray levels.

FilledSmallSquare ColorFunction -> Hue yields a range of colors.

FilledSmallSquare In three-dimensional graphics, ColorFunction is used only with the option setting Lighting -> False.

FilledSmallSquare See Section 1.9.5, Section 1.9.5, Section 1.9.6, Section 2.10.2 and Section 2.10.7.

FilledSmallSquare See also: ColorFunctionScaling, Lighting, ColorOutput.

FilledSmallSquare New in Version 2; modified in 4.0.

Further Examples