PermutationTests.jl

Univariate and multiple comparisons statistical hypothesis testing by data permutation
Author Marco-Congedo
Popularity
4 Stars
Updated Last
2 Months Ago
Started In
June 2024

PermutationTests.jl

A fast pure-julia package for univariate and multiple comparisons statistical hypothesis testing based on permutation theory.

Besides featuring an API with many tests, this package allows you to create your own permutation tests.


Installation

Execute the following command in julia's REPL:

]add PermutationTests

Available tests

All tests have a univariate and multiple comparisons version:

  • Pearson product-moment correlation
  • Trend correlation (fit of any kind of regression)
  • Point bi-serial correlation*
  • Student's t for independent samples
  • 1-way ANOVA for independent samples
  • Χ² for 2xK contingency tables*
  • Fisher exact test* (2x2 contingency tables)
  • Student's t for repeated-measures
  • 1-way ANOVA for repeated-measures
  • Cochran Q*
  • McNemar*
  • One-sample Student's t
  • Sign*

(* for dicothomous data)


Quick start

As an example, let's run a Pearson correlation univariate test:

using PermutationTests
# number of observations
N=10 
# some random Gaussian data
x, y = randn(N), randn(N) 
t = rTest(x, y)

The test result t is a structure and its fields are printed in yellow, looking like this:

Thus, for exmple, the p-value and the number of permutations used by the test are retrived such as

t.p
t.nperm

About the authors

Marco Congedo, corresponding author and developer of the package, is a Research Director of CNRS (Centre National de la Recherche Scientifique), working at UGA (University of Grenoble Alpes, France). Contact: first name dot last name at gmail dot com

Livio Finos, is Full professor at the Department of Statistical Sciences of Univerità di Padova, Italy. Contact: first name dot last name at unipd dot it


Disclaimer

This version has been roughly tested. Independent reviewers for both the code and the documentation are welcome.


Documentation

Used By Packages

No packages found.