Modeling Psychophysical Data in R: A Comparative Study of Four Model Frameworks
Priscilla BalestrucciiD, Maura MezzettiiD, Barbara La ScaleiaiD, Alessandro MoscatelliiD
Abstract
Inferential models in psychophysics are essential for quantifying the relation between physical properties of the stimulus and their perceptual representations. The psychometric function is typically used to model the responses of individual participants in forced-choice experiments. The accuracy and the noise of the response can be estimated from the Point of Subjective Equality (PSE) and the Just Noticeable Difference (JND) of the function, respectively. Traditionally, a two-level approach is used to model the behavior of a group of participants, where psychometric functions are first fitted to individual participant data, followed by hypothesis testing across participants on parameters of interest. Recent studies have introduced alternative approaches based on hierarchical models, such as Generalized Linear Mixed Models (GLMM) and Models within the Bayesian Hierarchical Framework (BHF), to analyze in a single framework the responses from multiple participants. These two approaches can be effectively implemented in R, thanks to its flexibility and robust statistical capabilities. Here, we provide a tutorial on how to model and analyze data from psychophysical experiments in R, using both two-level and hierarchical frameworks. Our goal is to provide researchers with a practical guide for building a complete and reproducible analysis pipeline, using core R functionalities together with custom packages, and facilitate rigorous and efficient data analysis in psychophysics.
02 /Specification & Classification
Click any tag to browse matching papers- Citations
- 0
- Research Focus
- Approach
Reproducibility ledger
Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.
Sign in to file a reproducibility report.
Related papers
- Psychophysics with R: The R Package MixedPsy
Priscilla Balestrucci, Marc O. Ernst, Alessandro Moscatelli·bioRxiv·Jun 20, 2022
- Hierarchical Bayesian Modelling of Interoceptive Psychophysics
Arthur S. Courtin, Jesper Fischer Ehmsen, … Micah Allen·bioRxiv·Aug 27, 2025
- EPHierStats: a statistical tool to model the hierarchical relationships in electrophysiological data
Jenya Kolpakova, Jonathan D. Marvel-Zuccola, … Vincent van der Vinne·bioRxiv·Mar 23, 2022
- Hemodynamic modelling improves population receptive field estimates
Dietrich Samuel Schwarzkopf, Ecem Altan, … Catherine Morgan·bioRxiv·Nov 17, 2025
- Revealing neuro-computational mechanisms of reinforcement learning and decision-making with the hBayesDM package
Woo‐Young Ahn, Nathaniel Haines, Lei Zhang·Computational PsychiatryPeer-reviewed·Aug 25, 2017
- Putting perception into action: Inverse optimal control for continuous psychophysics
D. Straub, C. A. Rothkopf·bioRxiv·Dec 23, 2021