If you are looking for a built-in function to do so, I don't know if it exists. With the documentation above you should be able to create yours according to your expectations. Otherwise, you can edit your question and add more information. Also lerp
function might be useful, see here