Typecasting the indices to integers to avoid range()'s anger while used with indexWindow