Am 19.10.2017 um 14:50 schrieb Artur T.:
I am facing the following simple problem
Are you sure you don't simply need the built-in resample() function?
for which I only find a loop
solution but loops are (generally?) slow compared to vectorized
approaches (if possible).
Actually, in my experience loops aren't so slow in hansl. There have
been cases where I invested some effort to replace a loop with some
matrix-oriented tricks and didn't get any speed gains. But of course it
depends on the particular case.
In MATLAB this works simply by: X = Y(SEL)
Have you tried Y[SEL] (square brackets, as with all indexation in hansl)?
cheers,
sven