stats(deprecated)/describe - Help

Overview of the stats[describe] Subpackage

 Calling Sequence stats[describe][command](arguments) command(arguments)

Description

 • Important: The stats package has been deprecated. Use the superseding package Statistics instead.
 • The  stats[describe] subpackage provides various descriptive statistical functions for the analysis of statistical data.
 • Each command in the stats[describe] package can be accessed by using either the long form or the short form of the command name in the command calling sequence.

List of stats[describe] Subpackage Commands

 • The following is a list of available commands.

 To display the help page for a particular stats[describe] command, see Getting Help with a Command in a Package.
 • The descriptive statistics functions are used to reduce each data sets to single numbers. Measures of central tendencies, such as the mean, or the median, represent data sets by values that are considered typical. Measures of dispersion, such as the standard deviation, are used to measure the spread of the data. The skewness measures the departure from symmetry of a distribution. The kurtosis measures the flatness of a distribution.
 • If a particular call cannot be evaluated, for example trying to find the mode of a statistical list that contains a non numerical entry, then the call is returned unevaluated. Information is provided in the variable stats/lasterror as to the reason why a call was not evaluated. Also, this information is automatically given if infolevel[stats] has a value greater than or equal to one, prior to the unsuccessful call.
 • See stats[data] on how to represent data for the stats package. The help page describe[gaps] provides more information about gaps between classes.
 • Some commands either require or use parameters in addition to the data given as arguments. These parameters appear as an index to the command name. For an example, see describe[standarddeviation].

Examples

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

 > $\mathrm{with}\left(\mathrm{stats}\right):$
 > $\mathrm{data}≔\left[\mathrm{Weight}\left(3,10\right),\mathrm{missing},4,\mathrm{Weight}\left(11..12,3\right)\right]$
 ${\mathrm{data}}{:=}\left[{\mathrm{Weight}}{}\left({3}{,}{10}\right){,}{\mathrm{missing}}{,}{4}{,}{\mathrm{Weight}}{}\left({11}{..}{12}{,}{3}\right)\right]$ (1)
 > $\mathrm{describe}[\mathrm{mean}]\left(\mathrm{data}\right)$
 $\frac{{137}}{{28}}$ (2)
 > $\mathrm{describe}[\mathrm{standarddeviation}]\left(\mathrm{data}\right)$
 $\frac{{1}}{{28}}{}\sqrt{{9385}}$ (3)

For standard deviation of a sample use

 > $\mathrm{describe}[\mathrm{standarddeviation}[1]]\left(\mathrm{data}\right)$
 $\frac{{1}}{{364}}{}\sqrt{{1708070}}$ (4)

 > $\mathrm{describe}[\mathrm{moment}[3,\mathrm{mean}]]\left(\mathrm{data}\right)$
 $\frac{{156165}}{{2744}}$ (5)

In floating points, this is:

 > $\mathrm{evalf}\left(\right)$
 ${56.91144315}$ (6)

A list of operations can be formed to apply on the same data

 > $\mathrm{description_functions}≔\left[{\mathrm{describe}}_{\mathrm{count}},{\mathrm{describe}}_{\mathrm{mean}},{\mathrm{describe}}_{\mathrm{variance}}\right]:$
 > $\mathrm{description_functions}\left(\mathrm{data}\right)$
 $\left[{14}{,}\frac{{137}}{{28}}{,}\frac{{9385}}{{784}}\right]$ (7)
 > $\mathrm{quartiles}≔\left[{\mathrm{describe}}_{{\mathrm{quartile}}_{1}},{\mathrm{describe}}_{{\mathrm{quartile}}_{2}},{\mathrm{describe}}_{{\mathrm{quartile}}_{3}}\right]:$
 > $\mathrm{quartiles}\left(\mathrm{data}\right)$
 $\left[{3}{,}{3}{,}\frac{{7}}{{2}}\right]$ (8)

References

 There are various books where more details about descriptive statistics can be found. An example of an introductory text is Murray R. Spiegel, Schaum's Outline of Theory and Problems of Statistics, Second Edition, McGraw-Hill, 1988. Of particular relevance to the describe subpackage are chapters 3,4,5, and 14.