Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
mean() and mean2()

Subject: mean() and mean2()

From: wanna mt

Date: 9 Oct, 2010 03:09:04

Message: 1 of 4

what is the differences of mean() and mean2()?is it mean() is specific for maths algorithm and mean2() is used for image processing?

Subject: mean() and mean2()

From: Ross W

Date: 9 Oct, 2010 04:18:04

Message: 2 of 4

"wanna mt" <wanna281@gmail.com> wrote in message <i8omcg$grr$1@fred.mathworks.com>...
> what is the differences of mean() and mean2()?is it mean() is specific for maths algorithm and mean2() is used for image processing?

If you have an array A, then
the difference is that mean(A) calculates a mean value for each column of A, whereas mean2(A) will calculate the mean of all the elements in A

e.g.
A=[1 2; 3 4]

now try mean(A) and mean2(A), and see what you get.

Ross

Subject: mean() and mean2()

From: wanna mt

Date: 11 Oct, 2010 04:08:03

Message: 3 of 4

"Ross W" <rosswoodskiwi@hotmail.com> wrote in message <i8oqds$3rr$1@fred.mathworks.com>...
> "wanna mt" <wanna281@gmail.com> wrote in message <i8omcg$grr$1@fred.mathworks.com>...
> > what is the differences of mean() and mean2()?is it mean() is specific for maths algorithm and mean2() is used for image processing?
>
> If you have an array A, then
> the difference is that mean(A) calculates a mean value for each column of A, whereas mean2(A) will calculate the mean of all the elements in A
>
> e.g.
> A=[1 2; 3 4]
>
> now try mean(A) and mean2(A), and see what you get.
>
> Ross

ok...now i get it..ok, thanx.. =)

Subject: mean() and mean2()

From: Greg Heath

Date: 13 Oct, 2010 01:43:00

Message: 4 of 4

On Oct 8, 11:09 pm, "wanna mt" <wanna...@gmail.com> wrote:
> what is the differences of mean() and mean2()?is it mean() is specific for maths algorithm and mean2() is used for image processing?

Whenever you have a question like this just type into the command line

help mean2
help mean

doc mean2
doc mean

Hope this helps.

Greg

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us