fixed bug for out of bag sampling