stats/test
alt-two-sided
(alt-two-sided :int)
alt-tag constant for two-sided tests.
Since: ST5
alt-less
(alt-less :int)
alt-tag constant for one-sided less tests.
Since: ST5
alt-greater
(alt-greater :int)
alt-tag constant for one-sided greater tests.
Since: ST5
make-test-result
(make-test-result [name :cstr statistic :float df1 :float df2 :float p-value :float alt-tag :int estimate :float ci-low :float ci-high :float conf-level :float] :int)
construct a test-result from components.
Since: ST5
test-result-free
(test-result-free [r :int] :void)
free a test-result.
Since: ST5
test-result-name
(test-result-name [r :int] :cstr)
test-result-statistic
(test-result-statistic [r :int] :float)
test-result-df1
(test-result-df1 [r :int] :float)
test-result-df2
(test-result-df2 [r :int] :float)
test-result-p-value
(test-result-p-value [r :int] :float)
test-result-alt-tag
(test-result-alt-tag [r :int] :int)
test-result-estimate
(test-result-estimate [r :int] :float)
test-result-ci-low
(test-result-ci-low [r :int] :float)
test-result-ci-high
(test-result-ci-high [r :int] :float)
test-result-conf-level
(test-result-conf-level [r :int] :float)
t-test-1samp
(t-test-1samp [col :int mu :float alt-tag :int conf-level :float] :int)
one-sample t-test: is mean(col) == mu?
| col | :int float64 column | |
| mu | :float hypothesized mean | |
| alt-tag | :int (alt-two-sided), (alt-less), or (alt-greater) | |
| conf-level | :float e.g. 0.95 |
:int test-result handle.
Since: ST5
t-test-2samp
(t-test-2samp [a :int b :int pooled :int alt-tag :int conf-level :float] :int)
two-sample t-test (Welch when pooled?=0).
| a | :int first column | |
| b | :int second column | |
| pooled | :int 0=Welch, 1=pooled | |
| alt-tag | :int | |
| conf-level | :float |
:int test-result handle.
Since: ST5
t-test-paired
(t-test-paired [a :int b :int alt-tag :int conf-level :float] :int)
paired t-test.
| a | :int column of first observations | |
| b | :int column of second (same length as a) | |
| alt-tag | :int | |
| conf-level | :float |
:int test-result handle.
Since: ST5
var-test
(var-test [a :int b :int alt-tag :int conf-level :float] :int)
F-test for equality of variances.
| a b alt-tag conf-level |
:int test-result with statistic=F, df1=na-1, df2=nb-1.
Since: ST5
cor-test
(cor-test [a :int b :int alt-tag :int conf-level :float] :int)
Pearson correlation test.
| a b alt-tag conf-level |
:int test-result with estimate=r, statistic=t.
Since: ST5
anova-oneway
(anova-oneway [cols :int] :int)
one-way ANOVA on a list of group columns.
| cols | cons list of :int (float64 columns, one per group) |
:int test-result with statistic=F, df1=k-1, df2=N-k.
Since: ST6
chi2-gof
(chi2-gof [observed :int expected :int] :int)
chi-squared goodness-of-fit test.
| observed | :int column of observed counts | |
| expected | :int column of expected counts (same length) |
:int test-result with statistic=chi^2, df=k-1.
Since: ST6
chi2-contingency
(chi2-contingency [f :int] :int)
chi-squared test of independence on a contingency frame.
| f | :int frame where each column is one category and each row is | |
| another; cell values are counts (float64). |
:int test-result.
Since: ST6
mann-whitney
(mann-whitney [a :int b :int alt-tag :int] :int)
Mann-Whitney U rank-sum test.
| a b alt-tag |
:int test-result with statistic=U.
Since: ST6
wilcoxon-signed-rank
(wilcoxon-signed-rank [a :int b :int alt-tag :int] :int)
Wilcoxon signed-rank test on paired observations.
| a b alt-tag |
:int test-result with statistic=W.
Since: ST6
ks-test-1samp
(ks-test-1samp [col :int d-dist :int alt-tag :int] :int)
one-sample Kolmogorov-Smirnov test against a continuous distribution.
| col | :int float64 column | |
| d-dist | :int distribution handle (from stats/dist) | |
| alt-tag | :int |
:int test-result with statistic=D.
Since: ST6
ks-test-2samp
(ks-test-2samp [a :int b :int alt-tag :int] :int)
two-sample Kolmogorov-Smirnov test.
| a b alt-tag |
:int test-result with statistic=D.
Since: ST6
Internal definitions
__tr-alloc__p-t-two__p-t-sided__p-chi2-sided