sampling: apply scaling after the loop