fixing bug #40 in wild resampling for CDE models