Sample index and bootstrap