updated for Resample changes