cluster-test

Cluster-based permutation testing in arbitrary dimensions, in a simple Matlab script.

https://github.com/spaak/cluster-test

Science Score: 67.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 1 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.5%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Cluster-based permutation testing in arbitrary dimensions, in a simple Matlab script.

Basic Info
  • Host: GitHub
  • Owner: Spaak
  • License: bsd-3-clause
  • Language: MATLAB
  • Default Branch: main
  • Size: 31.3 KB
Statistics
  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 1
Created almost 2 years ago · Last pushed over 1 year ago
Metadata Files
Readme License Citation

README.md

Cluster Test

DOI

Cluster-based permutation testing in arbitrary dimensions, in a simple Matlab script.

Note: requires Matlab imaging processing toolbox (bwconncomp function, specifically). This is available on most Matlab installations.

Main file (usable by itself) is cluster_test.m, with an optional helper cluster_test_helper.m. Docs are in those files.

From cluster_test.m: % CLUSTER_TEST performs a cluster-corrected test that datobs is higher/lower % than the distribution as expected under the null hypothesis. The 'null' % distribution should be pre-computed (manually or using CLUSTER_TEST_HELPER) % and entered as an argument into this function. % % datobs - observed data MxNx...xZ % datrnd - null distribution, MxNx...xZxPerm % tail - whether to test datobs < null (tail==-1), datobs > null (tail==1) % or datobs <> null (tail==0, default). % alpha - critical level (default 0.05) % clusteralpha - nonparametric threshold for cluster candidates (default % 0.05) % clusterstat - how to combine statistics in cluster candidates (can be % 'sum' (default) or 'size') % % Returns: % h - MxNx...xZ logical matrix indicating where significant clusters were % found (though note that formally speaking the test concerns the data as a % whole, so the interpretation of the location of clusters within h should % be done with caution). % p - MxNx...xZ matrix of p-values associated with clusters. % clusterinfo - struct with extra cluster info, e.g. indices % % Written by Eelke Spaak, Oxford University, June 2015.

From cluster_test_helper.m: % CLUSTER_TEST_HELPER is a helper function for doing cluster-corrected % permutation tests in arbitrary dimensions. The randomizations are % generated under the assumption that input dat was computed using a paired % statistic T for which T(a,b) = -T(b,a) holds, where a and b are the data % under the two paired conditions. (E.g. raw difference would work.) % % dat - an NxMx...xZxObs data matrix. The trailing dimension must correspond % to the unit of observation (e.g., subjects or trials). % % nperm - the number of permutations to generate % % diffstat - how to compute the 'difference statistic'. Can be 'diff' % (default) or 't' (compute one-sample t-score). % % Returns: % datobs - NxMx...xZ statistic for observed data, averaged across observations % datrnd - NxMx...xZxPerm statistic under the null hypothesis % % Written by Eelke Spaak, Oxford University, June 2015.

Owner

  • Name: Eelke Spaak
  • Login: Spaak
  • Kind: user

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: "Spaak"
  given-names: "Eelke"
title: "Cluster-based permutation testing in arbitrary dimensions, in a simple Matlab script."
version: 1.0
doi: 10.5281/zenodo.10877825
date-released: 2024-03-26
url: "https://github.com/Spaak/cluster-test"

GitHub Events

Total
  • Push event: 1
Last Year
  • Push event: 1

Committers

Last synced: about 1 year ago

All Time
  • Total Commits: 10
  • Total Committers: 1
  • Avg Commits per committer: 10.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 10
  • Committers: 1
  • Avg Commits per committer: 10.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Eelke Spaak e****k@g****m 10

Issues and Pull Requests

Last synced: 12 months ago

All Time
  • Total issues: 0
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 0
  • Total pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels