slider

Core Math

Create an interactive range slider. Returns the current numeric value.

Syntax

slider(label, min, max)
slider(label, min, max, default)
slider(label, min, max, default, step)

Examples

F = slider('Force', 0, 100, 50)
▶ Run
freq = slider('Frequency', 1, 1000, 440, 1)
▶ Run
x = linspace(0, 10, 100); plot(x, sin(slider('omega', 0.1, 10, 1) * x))
▶ Run

See Also

Try SimLab — Free MATLAB® Alternative

466 functions. Runs in your browser. No install.

Open SimLab

Stay Updated

Get notified about new simulations and tools. We send 1-2 emails per month.