Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

New to MATLAB?

what does this mean? say for a matrix W, W(:,:,1)

Asked by Rabeya

Rabeya (view profile)

on 5 Jun 2012

I have seen this in a program code, but don't know what it means. Say for example, for any matrix W, W(:,:,1). I know W(:,:) indicates all rows and columns in W, but what is meant by the last 1?



Rabeya (view profile)


1 Answer

Answer by Christoph

Christoph (view profile)

on 5 Jun 2012
Accepted answer

hi rabeye,

it's possible to store more than one matrix in a variable. The last element just indicates the level of the desired matrix.

To get a better clue just enter the command W = rand(5,4,3)

With kind regards, CN



Christoph (view profile)

Contact us