Means: Difference between revisions

From Eigenvector Research Documentation Wiki
Jump to navigation Jump to search
imported>Jeremy
(Importing text file)
imported>Donal
 
(One intermediate revision by one other user not shown)
Line 2: Line 2:
===Purpose===
===Purpose===


Calculates the algebraic, harmonic, and geometric mean of a vector.
Calculates the arithmetic, harmonic, and geometric mean of a vector.


===Synopsis===
===Synopsis===
Line 8: Line 8:
:vals = means(x)
:vals = means(x)


====INPUTS====
====Inputs====


* '''x''' = matrix (column vector) in which the sample data is stored.
* '''x''' = matrix (column vector) in which the sample data is stored.


====OUTPUTS====
====Outputs====


The return value is a structure with fields:
The return value is a structure with fields:

Latest revision as of 15:56, 5 September 2012

Purpose

Calculates the arithmetic, harmonic, and geometric mean of a vector.

Synopsis

vals = means(x)

Inputs

  • x = matrix (column vector) in which the sample data is stored.

Outputs

The return value is a structure with fields:

  • amean = arithmetic mean.
  • na = number of obs used in amean calculation.
  • hmean = harmonic mean.
  • nh = number of obs used in hmean calculation.
  • gmean = geometric mean.
  • ng = number of obs used in gmean calculation.

Examples

mns = means(x);

See Also

summary