yet another patch to the sub-sampling routine