Applying Movmedian Within Cell Array
Mostrar comentarios más antiguos
Hello,
I have a cell array (2 x 6) called "output", each cell in row #1 {1 -> 6, 2} contains a 1024 x 1024 x 100 matrix. I want to apply movmedian to each cells in row #1. I would like to apply this function in dimension = 3 with window size = 5.
output = cellfun(@movmedian(5,3), output,'uniform', 0);
This is the code that I have come up with so far, however, it produces an "unbalenced or unexpected parenthesis or bracket" error. I am unsure what is causing this error. I am also somewhat unsure how to instruct matlab to perform this operation only on row 1 of the cell array, please help!
Thank you for your time!!
4 comentarios
I still do not understand the notation "each cell in row #1 {1 -> 6, 2}". Please do not invent new terms without explaining it. The "row 1" of the cell C is "C(1, :)" [EDITED, was C(:,1)]. You can assume, that all readers are familiar with the Matlab syntax.
itend
el 24 de Ag. de 2017
Image Analyst
el 24 de Ag. de 2017
You say C is an array of cells with 2 rows of 6 columns ("2x6").
C(:,1) is a column vector of the 2 cells in column #
C(1,:) is a row vector of the 6 cells in row #1.
C(expression, 2) is a column vector extracted from only the rows identified in "expression" and only from column #2. So it would have either one cell or two cells since there are only two rows.
Not sure what you mean, but it's clear that reading this FAQ item might help: http://matlab.wikia.com/wiki/FAQ#What_is_a_cell_array.3F
itend
el 25 de Ag. de 2017
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Timing and presenting 2D and 3D stimuli en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
