Cell



In the APL array model and in particular leading axis theory, a cell of an array is a subarray which is formed by selecting a single index along some number of leading axes and the whole of each trailing axis. Cells are classified by their rank, which may be between 0 (scalars) and the array's rank (in which case the cell must be the entire array). Cells with rank  are called k-cells of an array. A major cell is a cell whose rank is one less than the entire array, or a 0-cell of a scalar.

Leading and trailing axes
The k-cells of an array with rank  share the last   axes with that array, and collapse the first   axes by choosing a single index along each of them. Using bracket indexing this can be written while Squad indexing allows a cell to be selected without knowing the argument's rank.