A method for fitting regression splines with varying polynomial order in the linear mixed model