add query param to resample, closes #478