Is there a function that does the following?
Given a matrix
0 0 0
1 1 1
0 0 0
And a 1-D array of "shifting values"
0 1 2
The function would shift all the values, column wise, where each shift per column is specified by shifting_values
?
For example
> np.f(X, shifting_values,axis=1)
0 0 1
1 0 0
0 1 0
Does such a function exist? If not, is it possible to do this without using a for loop?