Hi, I'm new to matlab and wanted to find the mean of all the values in my matrix/data set and was wondering how I would do this?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Sara Renmiu
le 16 Mai 2020
Réponse apportée : Mathias Andersen
le 16 Mai 2020
This
mean(a(:))
has been suggested but it has not worked for me.
0 commentaires
Réponse acceptée
Mathias Andersen
le 16 Mai 2020
See the documentation for the mean command here
So if you want the mean of an entire matrix write the following
mean(a,'all')
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Shifting and Sorting Matrices dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!