What you're looking for is some kind of
InterpolationYou should make a function along these lines: NOT AT ALL TESTED, 'PSEUDOCODE'
float animatedValue(int currentFrame, int startFrame, int endFrame, int easeIn, int easeOut, int positionFrom, int positionTo) {
float positionModifier = 0;
float easeInProgress = (currentFrame - startFrame) / easeIn;
//use easeInProgress (which is from 0 to 1 and above) to generate your position while it eases in
//calculate positionModifier
float easeOutProgress = (currentFrame - (endFrame - easeOut)) / easeOut;
//same as the previous
//calculate positionModifier
//if neither ease in or ease out
return positionTo;
//else
return (float)positionFrom + positionModifier;
}