How could I extract last column in a matrix if I don't know the size of matrix?

I want to select only last coloumn..because in my program the size of matices is change every time..these are some example of my matices
(150x23)
(150x34)
(150*41)
...etc

 Akzeptierte Antwort

matrix(:,end)

3 Kommentare

@ madhan ravi, thanks alot,, and how could I select all the coulomns except the last coulomn? thanks for helping
thank you helpful me

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by