fix error when data had only one dimension, and you wanted only one value