Neural Network Toolbox Previous page   Next Page
vec2ind

Convert vectors to indices

Syntax

Description

ind2vec and vec2ind allow indices to be represented either by themselves or as vectors containing a 1 in the row of the index they represent.

vec2ind(vec) takes one argument,

and returns the indices of the 1's.

Examples

Here four vectors (each containing only one "1" element) are defined and the indices of the 1's are found.

See Also


Previous page  tribas Glossary Next page

© 1994-2005 The MathWorks, Inc.