I am quite new to Julia language. I would like to know if this language implements some statistical tests, in particular t-test for comparison of means.And if so, how can I invoke it?
You can use HypothesisTests.jl for this -- relevant docs.
(See also: The website juliastats.github.io neatly lists packages in Julia for stats and ML)
Here's how you could probably go about it:
julia> Pkg.add("HypothesisTests")
julia> using HypothesisTests
julia> xs = [1, 2, 3, 4]
julia> ys = [5, 6, 7, 8]
julia> OneSampleTTest(vec(xs), vec(ys))
One sample t-test
-----------------
Population details:
parameter of interest: Mean
value under h_0: 0
point estimate: -4.0
95% confidence interval: (-4.0,-4.0)
Test summary:
outcome with 95% confidence: reject h_0
two-sided p-value: 0.0 (extremely significant)
Details:
number of observations: 4
t-statistic: -Inf
degrees of freedom: 3
empirical standard error: 0.0
(... above example just illustrates the usage of the function, data does not mean anything).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With