Filter löschen
Filter löschen

sum of each column of matrix

1 Ansicht (letzte 30 Tage)
Berbia
Berbia am 8 Jan. 2013
I need to create a vector from a matrix by adding each column elements to form a corresponding vector component. matrix columns are fixed dimension 200. My result should be a row vector of dimension 200. How to do it simply in matlab??

Akzeptierte Antwort

Azzi Abdelmalek
Azzi Abdelmalek am 8 Jan. 2013
Bearbeitet: Azzi Abdelmalek am 8 Jan. 2013
A=rand(300,200);
out=sum(A)

Weitere Antworten (0)

Kategorien

Mehr zu Multidimensional Arrays finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by