Skip to content

yticks

Ticks for the y-axis

yticks(ticks)

  • The argument ticks is a vector of tick numbers.
  • This switches to manual mode, and sets the tick values.
  • If ticks is empty, it will show no ticks.
  • ticks should not contain Inf and NaN values.

ticks = yticks

  • It returns current tick values.

yticks('auto')

  • It switches to auto mode, and ticks are generated automatically.

yticks('manual')

  • It switches to manual mode.

yticks('mode')

  • It returns the current mode, which is either 'auto' or 'manual'.

Note

  • If the hold state is off, execution of the next plot or surf function will reset it to auto mode; otherwise, the mode remains unchanged.
  • Touch interactions do not change the mode.
  • If it is in manual mode, touch interactions do not change the tick values; otherwise, tick values are generated automatically.