how to write the mean equation

How do I manually enter the mean equation?

1 Comment

mean of what? There's a mean function that does it for you. Otherwise you can use
doc sum
if you really want to do it without the mean function.
Or you can add all your numbers together in a for loop if you don't want to use sum either.

Sign in to comment.

Answers (1)

Stephan
Stephan on 17 Sep 2019
Edited: Stephan on 17 Sep 2019
A_mean = sum(A,'all')/numel(A)

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Tags

Asked:

on 17 Sep 2019

Edited:

on 17 Sep 2019

Community Treasure Hunt

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

Start Hunting!