better type and dimension checking for indices in structure_at
Merge pull request #98 from keflavich/structure_at_indexing

Minor change: check type of index before using it