setting up index