Maxima – 230 – descriptive – 7

elea1

Continuo da qui, copio dal Reference Manual, PDF scaricabile da qui, sono a p.724.

skewness (list)
skewness (matrix)
The skewness coefficient, defined as

230-0

(%i1) load ("descriptive")$

(%i2) s1 : read_list (file_search ("pidigits.data"))$

(%i3) skewness (s1), numer;
(%o3)                        0.009196180476450307
(%i4) s2 : read_matrix (file_search ("wind.data"))$

(%i5) skewness (s2);
(%o5) [0.1580509020000979, 0.2926379232061853, 0.09242174416107717,
                                        0.2059984348148686, 0.2142520248890831]

See also functions mean, var and kurtosis.

pearson_skewness (list)
pearson_skewness (matrix)
Pearson’s skewness coefficient, defined as

230-1

where med is the median of list.

(%i6) s1 : read_list (file_search ("pidigits.data"))$

(%i7) pearson_skewness (s1), numer;
(%o7)                         0.2159484029093895
(%i8) s2 : read_matrix (file_search ("wind.data"))$

(%i9) pearson_skewness (s2);
(%o9) [- 0.08019976629211892, 0.2357036272952649, 0.1050904062491203,
                                        0.1245042340592367, 0.4464181795804519]

See also functions mean, var and median.

quartile_skewness (list)
quartile_skewness (matrix)
The quartile skewness coefficient, defined as

230-2

where cp is the p-quantile of sample list.

(%i10) s1 : read_list (file_search ("pidigits.data"))$

(%i11) quartile_skewness (s1), numer;
(%o11)                        0.04761904761904761
(%i12) s2 : read_matrix (file_search ("wind.data"))$

(%i13) quartile_skewness (s2);
(%o13) [- 0.0408542246982353, 0.1467025572005382, 0.03362391033623919,
                                       0.03780068728522298, 0.2105263157894735]

See also function quantile.

km (list, option ...)
km (matrix, option ...)
Kaplan Meier estimator of the survival, or reliability, function S(x) = 1 − F (x).

Data can be introduced as a list of pairs, or as a two column matrix. The first component is the observed time, and the second component a censoring index (1 = non censored, 0 = right censored).

The optional argument is the name of the variable in the returned expression, which is x by default.

(%i14) S: km([[2,1], [3,1], [5,0], [8,1]]);
                        charfun((3 <= x) and (x < 8))
(%o14) charfun(x < 0) + -----------------------------
                                      2
                3 charfun((2 <= x) and (x < 3))
              + ------------------------------- + charfun((0 <= x) and (x < 2))
                               4
(%i15) load ("draw")$

(%i16) draw2d(line_width = 3, grid = true, explicit(S, x, -0.1, 10))$

230-3

Estimate survival probabilities.

(%i17) S(t):= ''(km([[2,1], [3,1], [5,0], [8,1]], t))$

(%i18) S(6);
                                       1
(%o18)                                 -
                                       2

Posta un commento o usa questo indirizzo per il trackback.

Trackback

Rispondi

Inserisci i tuoi dati qui sotto o clicca su un'icona per effettuare l'accesso:

Logo WordPress.com

Stai commentando usando il tuo account WordPress.com. Chiudi sessione /  Modifica )

Google photo

Stai commentando usando il tuo account Google. Chiudi sessione /  Modifica )

Foto Twitter

Stai commentando usando il tuo account Twitter. Chiudi sessione /  Modifica )

Foto di Facebook

Stai commentando usando il tuo account Facebook. Chiudi sessione /  Modifica )

Connessione a %s...

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d blogger hanno fatto clic su Mi Piace per questo: