added MleJointStage function