Student[Statistics] - Maple Programming Help

Home : Support : Online Help : Education : Student Package : Statistics : Student/Statistics/Skewness

Student[Statistics]

 Skewness
 compute the coefficient of skewness

 Calling Sequence Skewness(A, numeric_option) Skewness(M, numeric_option) Skewness(X, numeric_option, inert_option)

Parameters

 A - M - X - algebraic; random variable numeric_option - (optional) equation of the form numeric=value where value is true or false inert_option - (optional) equation of the form inert=value where value is true or false

Description

 • The Skewness function computes the coefficient of skewness of the specified random variable or data set. In the data set case the following formula for computing the coefficient of skewness is used:

$\mathrm{Skewness}\left(A\right)=\frac{N\mathrm{Moment}\left(A,3,\mathrm{origin}=\mathrm{Mean}\left(A\right)\right)}{\left(N-1\right){\mathrm{StandardDeviation}\left(A\right)}^{3}},$

 where N is the number of elements in A.
 • The first parameter can be a data sample (e.g., a Vector), a Matrix data sample, a random variable, or an algebraic expression involving random variables (see Student[Statistics][RandomVariable]).
 • If the option inert is not included or is specified to be inert=false, then the function will return the actual value of the result. If inert or inert=true is specified, then the function will return the formula of evaluating the actual value.

Computation

 • By default, all computations involving random variables are performed symbolically (see option numeric below).
 • If there are floating point values or the option numeric is included, then the computation is done in floating point. Otherwise the computation is exact.
 • By default, the skewness is computed according to the rules mentioned above. To always compute the skewness numerically, specify the numeric or numeric = true option.

Examples

 > $\mathrm{with}\left(\mathrm{Student}[\mathrm{Statistics}]\right):$

Compute the coefficient of skewness of the log normal random variable with parameters $\mathrm{\mu }$ and $\mathrm{\sigma }$.

 > $\mathrm{Skewness}\left(\mathrm{LogNormalRandomVariable}\left(\mathrm{μ},\mathrm{σ}\right)\right)$
 $\frac{{{ⅇ}}^{{3}{}{\mathrm{μ}}{+}\frac{{9}}{{2}}{}{{\mathrm{σ}}}^{{2}}}{-}{3}{}{{ⅇ}}^{{3}{}{\mathrm{μ}}{+}\frac{{5}}{{2}}{}{{\mathrm{σ}}}^{{2}}}{+}{2}{}{{ⅇ}}^{{3}{}{\mathrm{μ}}{+}\frac{{3}}{{2}}{}{{\mathrm{σ}}}^{{2}}}}{{\left({{ⅇ}}^{{{\mathrm{σ}}}^{{2}}{+}{2}{}{\mathrm{μ}}}{}\left({{ⅇ}}^{{{\mathrm{σ}}}^{{2}}}{-}{1}\right)\right)}^{{3}{/}{2}}}$ (1)

Use numeric parameters for the beta random variable.

 > $\mathrm{Skewness}\left(\mathrm{BetaRandomVariable}\left(2,7\right)\right)$
 $\frac{{10}}{{77}}{}\sqrt{{35}}$ (2)
 > $\mathrm{Skewness}\left(\mathrm{BetaRandomVariable}\left(2,7\right),\mathrm{numeric}\right)$
 ${0.7683220505}$ (3)

Use the inert option.

 > $\mathrm{Skewness}\left(\mathrm{BetaRandomVariable}\left(2,7\right),\mathrm{inert}\right)$
 $\frac{{{∫}}_{{0}}^{{1}}\left({-}{56}{}{\left({-}{\mathrm{_t2}}{+}{{∫}}_{{0}}^{{1}}{56}{}{{\mathrm{_t1}}}^{{2}}{}{\left({-}{1}{+}{\mathrm{_t1}}\right)}^{{6}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{_t1}}\right)}^{{3}}{}{\mathrm{_t2}}{}{\left({-}{1}{+}{\mathrm{_t2}}\right)}^{{6}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{_t2}}}{{\left({{∫}}_{{0}}^{{1}}{56}{}{\left({-}{\mathrm{_t0}}{+}{{∫}}_{{0}}^{{1}}{56}{}{{\mathrm{_t}}}^{{2}}{}{\left({-}{1}{+}{\mathrm{_t}}\right)}^{{6}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{_t}}\right)}^{{2}}{}{\mathrm{_t0}}{}{\left({-}{1}{+}{\mathrm{_t0}}\right)}^{{6}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{_t0}}\right)}^{{3}{/}{2}}}$ (4)
 > $\mathrm{evalf}\left(\mathrm{Skewness}\left(\mathrm{BetaRandomVariable}\left(2,7\right),\mathrm{inert}\right)\right)$
 ${0.7683220503}$ (5)

Consider the following list of data.

 > $A≔\left[1,2,-3,3.0,2,\mathrm{π}\right]$
 ${A}{≔}\left[{1}{,}{2}{,}{-}{3}{,}{3.0}{,}{2}{,}{\mathrm{π}}\right]$ (6)
 > $\mathrm{Skewness}\left(A\right)$
 ${-}{1.22868166495079}$ (7)

Consider the following Matrix data sample.

 > $M≔\mathrm{Matrix}\left(\left[\left[3.0,3.8,114\right],\left[4,\mathrm{ln}\left(7\right),128\right],\left[\mathrm{π},97,200\right]\right]\right)$
 ${M}{≔}\left[\begin{array}{ccc}{3.0}& {3.8}& {114}\\ {4}& {\mathrm{ln}}{}\left({7}\right)& {128}\\ {\mathrm{π}}& {97}& {200}\end{array}\right]$ (8)

Compute the skewness of each of the columns.

 > $\mathrm{Skewness}\left(M\right)$
 $\left[\begin{array}{ccc}{0.533197949150949}& {0.576594538650996}& \frac{{57275}}{{15302454}}{}\sqrt{{6388}}{}\sqrt{{3}}\end{array}\right]$ (9)

References

 Stuart, Alan, and Ord, Keith. Kendall's Advanced Theory of Statistics. 6th ed. London: Edward Arnold, 1998. Vol. 1: Distribution Theory.

Compatibility

 • The Student[Statistics][Skewness] command was introduced in Maple 18.