| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Image Processing Toolbox |
| Contents | Index |
| Learn more about Image Processing Toolbox |
A = col2im(B,[m n],[mm nn],'distinct')
A = col2im(B,[m n],[mm nn],'sliding')
A = col2im(B,[m n],[mm nn],'distinct') rearranges each column of B into a distinct m-by-n block to create the matrix A of size mm-by-nn. If B = [A11(:) A21(:) A12(:) A22(:)], where each column has length m*n, then A = [A11 A12; A21 A22] where each Aij is m-by-n.
A = col2im(B,[m n],[mm nn],'sliding') rearranges the row vector B into a matrix of size (mm-m+1)-by-(nn-n+1). B must be a vector of size 1-by-(mm-m+1)*(nn-n+1). B is usually the result of processing the output of im2col(...,'sliding') using a column compression function (such as sum).
col2im(B,[m n],[mm nn]) is the same as col2im(B, [m n], [mm nn],'sliding').
B can be logical or numeric. The return value A is of the same class as B.
B = reshape(uint8(1:25),[5 5])' C = im2col(B,[1 5]) A = col2im(C,[1 5],[5 5],'distinct')
blockproc, colfilt, im2col, nlfilter
![]() | checkerboard | colfilt | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |