Computes and compares multiple measures of separation and overlap between phonological categories (for example vowels or consonants) in arbitrary multi-dimensional acoustic spaces such as formant values, mel-frequency cepstral coefficients (MFCCs), duration, or learned embeddings. The main entry point, phontrast(), reports several contrast metrics in one call – Jensen-Shannon divergence and distance (Lin, 1991) <doi:10.1109/18.61115>, the Pillai-Bartlett trace, Bhattacharyya distance and affinity, Mahalanobis distance, and proportional overlap – globally or by group on a common separation-oriented scale, with bootstrap confidence intervals. Also provides utilities for preparing estimates for downstream modelling such as generalized additive models and mixed-effects models. Formerly released as 'phonJSD'.
| Version: | 2.3.1 |
| Depends: | R (≥ 4.1.0) |
| Imports: | ks, dplyr, purrr, tibble, rlang, stats, grDevices, utils |
| Suggests: | ggplot2, mgcv, mvtnorm, tuneR, testthat (≥ 3.0.0), knitr, rmarkdown |
| Published: | 2026-08-09 |
| DOI: | 10.32614/CRAN.package.phontrast (may not be active yet) |
| Author: | Grant M. Berry [aut, cre] |
| Maintainer: | Grant M. Berry <berry.grant at gmail.com> |
| BugReports: | https://github.com/berrygrant/phontrast/issues |
| License: | MIT + file LICENSE |
| URL: | https://github.com/berrygrant/phontrast |
| NeedsCompilation: | no |
| Citation: | phontrast citation info |
| Materials: | README, NEWS |
| CRAN checks: | phontrast results |
| Reference manual: | phontrast.html , phontrast.pdf |
| Vignettes: |
Multidimensional workflows (source, R code) Quick start: from vowel table to metrics and plots (source, R code) |
| Package source: | phontrast_2.3.1.tar.gz |
| Windows binaries: | r-devel: not available, r-release: not available, r-oldrel: not available |
| macOS binaries: | r-release (arm64): not available, r-oldrel (arm64): not available, r-release (x86_64): not available, r-oldrel (x86_64): not available |
Please use the canonical form https://CRAN.R-project.org/package=phontrast to link to this page.