Basic AS2 + Flash IDE Question

A question about how Actionscript interacts with the IDE timeline…

If I want to have my MC bobbing slightly from side to side, does the timeline have to be playing, or can it be stopped? If I was using sin() for the MC position displacement, what would be driving it - a timer, system clock, other?

I’ve done AS3 straight from 100% code - never done anything with the timeline before. I’m trying to understand how keyframed motion coexists with programmatic motion.