Produce a vector B which contain the average of each column of matrix A

5 views (last 30 days)
i have a matrix A has a random number of row 1 and 5 and random number of column between 1 and 10. how can i create a vector B which contain the average of each column of matrix A?

Answers (1)

Star Strider
Star Strider on 15 Aug 2021
Use the mean function.

Tags

Community Treasure Hunt

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

Start Hunting!