O'Reilly logo

An Engineer's Guide to Mathematica by Edward B. Magrab

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

9 Statistics

9.1 Descriptive Statistics

9.1.1 Introduction

Descriptive statistics are used to describe the properties of data; that is, how their values are distributed. One class of descriptors is concerned with the location of where the data tends to aggregate as typically described by the mean, median, or root mean square (rms). A second class of descriptors is concerned with the amount of dispersion of the data as typically described by the variance (or standard deviation) or by its quartiles. A third class of descriptors is the shape of the data as typically indicated by its histogram and its closeness to a known probability distribution. The commands used to determine these statistical descriptors are introduced in this section.

9.1.2 Location Statistics: Mean[], StandardDeviation[], and Quartile[]

The location statistics that we shall illustrate are the mean, median, and rms values, respectively, which are determined from


Mean[dat]
Median[dat]
RootMeanSquare[dat]

where dat is a list of numerical values representing measurements from a random process.

To illustrate these and other statistical functions, we shall consider the following data


datex1={111.,103.,251.,169.,213.,140.,224.,205.,166.,202.,
  227.,160.,234.,137.,186.,184.,163.,157.,181.,207.,189.,
  159.,180.,160.,196.,82.,107.,148.,155.,206.,192.,180.,
  205.,121.,199.,173.,177.,169.,93.,182.,127.,126.,187.,
  166.,200.,190.,171.,151.,166.,156.,187.,174.,164.,214.,
  139.,141.,178.,177.,243.,176.,186.,173.,182.,164.,162., ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required