Check out `clamp` for your second question: http://docs.julialang.org/en/latest/stdlib/base/#Base.clamp
On Wed, Jul 23, 2014 at 10:07 AM, Andrei Berceanu <andreiberce...@gmail.com> wrote: > Hi guys, > > I have 2 short numpy-related questions. > > In numpy, if one can invert an arbitrary array *arr* along a given axis > using the syntax > > *arr[::-1,...]* > > What is the equivalent idiom in Julia? > > The other issue is, how can I truncate an array between a lower and upper > bound? > In numpy, this is easily done with np.clip: > > http://docs.scipy.org/doc/numpy/reference/generated/numpy.clip.html > > Tnx! > A > >