updated ndarray __setitem__ for n-dim value