Coordinate System Transformations for Imitation of Goal-Directed Trajectories in Virtual Humans