26
$\begingroup$

Can you set the speed at which a Manipulate plays when the play button is clicked?

$\endgroup$
27
$\begingroup$

AnimationRate is at least one way to do this, and it can be applied on a per-control basis:

Manipulate[x, {x, 0, 10, AnimationRate -> 1/10, Appearance -> "Open"}]

Manipulate[x, {x, 0, 10, AnimationRate -> 10, Appearance -> "Open"}]
$\endgroup$
  • $\begingroup$ I couldn't see this option in the online documentation for Manipulate - although it can be easy to miss things. If it isn't there I think it would be a good addition. $\endgroup$ – cormullion May 16 '12 at 6:20
  • $\begingroup$ What is the Appearance -> "Open" doing? $\endgroup$ – becko Jan 28 '16 at 10:03
  • 2
    $\begingroup$ @becko It allows the play button to be visible without needing to first click the '+' next to the slider. $\endgroup$ – Brett Champion Jan 28 '16 at 15:27
13
$\begingroup$

I presume you are looking for AnimationRate.
Also, if you want smooth motion you should consider RefreshRate.

Manipulate[
 Plot[Sin[x + a], {x, 0, 5 Pi}],
 {a, 0, 2 Pi, ControlType -> Animator, AnimationRate -> 1, RefreshRate -> 60}
]
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.