describe(deprecated)/mean - Help

stats[describe, mean]

Arithmetic Mean of a Statistical List

 Calling Sequence stats[describe, mean](data) describe[mean](data)

Parameters

 data - statistical list

Description

 • Important: The stats package has been deprecated. Use the superseding package Statistics instead.
 • The function mean of the subpackage stats[describe, ...] computes the arithmetic mean of the given data.
 • The mean is defined to be the ratio of the sum of the data items (each multiplied by its weight) to the total weight.
 • Classes are assumed to be represented by the class mark, which is the mid-point of the class. For example, the class mark of the class 10..12 has the value 11. Missing data are simply ignored.
 • The mean is an example of a measure of central tendency of the data. Such measures are used to find a typical'' value for the data. Other measures of central tendency are the harmonic mean, the geometric mean, the quadratic mean, the median, and the mode.
 • A major advantage of using the mean as a measure of the central tendency is that it has a simple relation to the weighted sum of the data. It is arguably the most familiar central tendency  measure.
 • A disadvantage of using the mean as a measure of the central tendency is that it is strongly affected by the extreme values in the data. For example, if one wants to compute the typical salary on the payroll of a sports team that has one star player that is paid substantially more than her teammates it is more appropriate to use the median.
 • The command with(stats[describe],mean) allows the use of the abbreviated form of this command.

Examples

Important: The stats package has been deprecated. Use the superseding package Statistics instead.

 > $\mathrm{with}\left(\mathrm{stats}\right):$

What is the average  of the numbers 3 and 5

 > $\mathrm{describe}[\mathrm{mean}]\left(\left[3,5\right]\right)$
 ${4}$ (1)

A more complicated example

 > $\mathrm{data}≔\left[\mathrm{Weight}\left(3,10\right),\mathrm{missing},4,\mathrm{Weight}\left(11..13,3\right)\right]$
 ${\mathrm{data}}{:=}\left[{\mathrm{Weight}}{}\left({3}{,}{10}\right){,}{\mathrm{missing}}{,}{4}{,}{\mathrm{Weight}}{}\left({11}{..}{13}{,}{3}\right)\right]$ (2)
 > $\mathrm{describe}[\mathrm{mean}]\left(\mathrm{data}\right)$
 ${5}$ (3)
 > $\frac{10\cdot 3+1\cdot 4+\frac{3\left(11+13\right)}{2}}{10+1+3}$
 ${5}$ (4)