quad_qaws SciMax Toolbox quantile_bernoulli

SciMax Toolbox >> quantile

quantile

Maxima Function

Calling Sequence

quantile (list, p)
quantile(matrix,p)

Description

This is the p-quantile, with p a number in [0, 1], of the sample list. Although there are several definitions for the sample quantile (Hyndman, R. J., Fan, Y. (1996) Sample quantiles in statistical packages. American Statistician, 50, 361-365), the one based on linear interpolation is implemented in package descriptive.

Example:

(%i1) load (descriptive)$
(%i2) load (numericalio)$
(%i3) s1 : read_list (file_search ("pidigits.data"))$
(%i4) /* 1st and 3rd quartiles */
         [quantile (s1, 1/4), quantile (s1, 3/4)], numer;
(%o4)                      [2.0, 7.25]
(%i5) s2 : read_matrix (file_search ("wind.data"))$
(%i6) quantile (s2, 1/4);
(%o6)    [7.2575, 7.477500000000001, 7.82, 11.28, 11.48]
quad_qaws SciMax Toolbox quantile_bernoulli