fixed indexing problems for non-axial data