GBLK computes index templates of the form segment:offset for very fast extraction of data blocks from 2d matrices of any type.
data blocks can be non-, partial-, or fully overlapping.
the output can be reused to extract data from other matrices of the same size.
the templates can be modified to extract only selected data blocks and/or to extract only selected values from a data block.
CELLFUN can be used to compute further results from the extracted data blocks
> help gblk
and the accompanying published M-file for info and a few self-explanatory examples.
· MATLAB Release: R2007a