cns_iconvIn MATLAB, elements of an N-D array can be accessed using any number of indices from 1 to N. When using D < N indices, the dimensions (D : N) are treated as a single dimension, indexed by the Dth index. This can be quite useful.
This function is a generalization of MATLAB's sub2ind and ind2sub functions. cns_iconv converts indices between any two representations (D1 ≤ N) and (D2 ≤ N).
[j1, j2, ...] = cns_iconv(m, z, i1, i2, ...) |
m
z
i1, i2, ...z. From 1 to N numbers, where N is the dimensionality of the layer. These can also be arrays (for multiple cells), but must all be of the same size.
j1, j2, ...j will be the same size as the i inputs.