Documentation

spinmap

Rotate colormap colors

Syntax

spinmap
spinmap(t)
spinmap(t,n)

Description

spinmap当前旋转colormap repeatedl两行y for approximately three seconds.

spinmap(t)当前旋转colormap repeatedl两行y fortseconds.

example

spinmap(t,n)rotates the current colormap bynrows fortseconds.

Examples

collapse all

Create a surface plot that uses the default colormap. Then rotate the colormap by one row for five seconds.

surf(peaks); colorbar spinmap(5,1)

Input Arguments

collapse all

Rotation duration, specified as a scalar numeric value or'inf'. A numeric value specifies the number of seconds to rotate the colormap. A value of'inf'makes the colormap rotate indefinitely.

Rotation amount, specified as a numeric scalar value. The first rotation shifts each color in the colormap bynrows. Subsequent rotations shift the colormap by an additionalnrows.

Positive values increment the rows, where the last color wraps to the first row. A negative value decrements the rows, where the first color wraps to the last row.

Tips

PressCtrl+Cto interrupt the rotation beforethas elapsed.

Introduced before R2006a

Was this topic helpful?