changed sample index