What you want is similar to my servo library. It allows a script in the form of an array in memory. It is designed for easing movements which change at least a few times per second. The data is meant to come from animation software, but I have yet to figure out how to export and import properly. How are you coming along?