AFAICT initialAxis is undefined here. Should be axis[0]?