Quaternion PCA and sparse PCA for shape variability