added function to reset samples