I'm on my phone, but the Wiki should be able to provide examples.
function example()
setCameraMatrix(..)
end
addEventHandler("onPlayerJpin, root, example)
setTimer(example, 10000, 1 ...)
And you would repeat that, except removing the event handler. One event handler would act as the first one.