Two Distinct Interbrain Synchrony Mechanisms Carry Opposite Consequences for Collective Decision Accuracy
Description
**Dataset Title:** Data and Code for: Two Distinct Interbrain Synchrony Mechanisms Carry Opposite Consequences for Collective Decision Accuracy **Description:** This repository contains all data and code necessary to reproduce the analyses reported in the accompanying manuscript. The study investigated the neural dynamics of collective decision-making using a cooperative two-armed bandit task with fNIRS hyperscanning (N = 108 participants, 54 dyads). Before use, all zipped folders should be unzipped in place, preserving the existing directory structure. **Repository Structure:** **bayesian_ideal_observer.R** (root level). Implements the Bayesian ideal observer model: Normal–Normal conjugate updating, softmax allocation policy, maximum likelihood estimation of inverse temperature β, and autonomous counterfactual simulation (1,000 iterations). Input: RewardFeedBackTable.xlsx from the behavioral pipeline. Output: reward_feedback_with_model_allocation.xlsx. **Behavioral Data Preparation and Exploratory Analysis/**. Raw behavioral CSV files exported from Gorilla (one per participant) are in Arrange Data/Input/. Two R scripts process these into analysis-ready datasets in Arrange Data/Output/: ArrangeBehavioralData.R produces cleaned datasets for joint decisions, private decisions, alignment measures, and exploration behavior; ArrangeRewardFeedbackTable.R constructs the trial-level reward feedback table with experienced outcomes and running value signals. See the included README.docx for full variable definitions. **Neural Data Preparation and Exploratory Analysis/**. Raw Data/ contains 102 SNIRF files (one per participant) recorded with a NIRx system (10 Hz, 760/850 nm, 46 channels per participant). Preprocessing (channel rejection via SCI, motion correction via TDDR, short-channel regression, bandpass filtering) was performed in Satori software (NIRx). WTC Data/Input/ contains wavelet transform coherence output computed between homologous channels (Morlet wavelet, ω₀ = 6, 0.044–0.16 Hz) for real and pseudo-dyads. Two R scripts (ArrangeWTCData_RealGroups_DiscussionPhase.R and ArrangeWTCData_PseudoGroups_DiscussionPhase.R) process these into ROI-level IBS estimates in WTC Data/Output/. Supplementary files/ contains channel-to-ROI mappings, MNI coordinates, SCI data, event extraction scripts (R and MATLAB), and WTC configuration files. EDA/Compare-Real-To-Pseudo-Groups.R implements the pseudo-dyad validation analysis. **Brain-Behavior Analysis/**. Full Analysis Pipeline.R is the main analysis script. It merges processed behavioral and IBS data and implements all statistical models reported in the manuscript: alignment analyses, IBS × disagreement interaction models, second-stage accuracy analyses, and behavioral convergence analyses.
Files
Steps to reproduce
Reproduction Steps: Run Behavioral Data Preparation and Exploratory Analysis/Arrange Data/ArrangeBehavioralData.R to process raw participant CSV files into cleaned behavioral datasets. Run Behavioral Data Preparation and Exploratory Analysis/Arrange Data/ArrangeRewardFeedbackTable.R to construct the trial-level reward feedback table from joint decisions and reward outcomes. Run Neural Data Preparation and Exploratory Analysis/WTC Data/ArrangeWTCData_RealGroups_DiscussionPhase.R and ArrangeWTCData_PseudoGroups_DiscussionPhase.R to process raw WTC output into ROI-level interbrain synchrony estimates. Run Neural Data Preparation and Exploratory Analysis/EDA/Compare-Real-To-Pseudo-Groups.R to validate that real dyads exhibit significantly higher IBS than pseudo-dyads. Run bayesian_ideal_observer.R (root level) to compute trial-by-trial optimal allocations, allocation error, and the counterfactual simulation. Run Brain-Behavior Analysis/Full Analysis Pipeline.R to merge behavioral and neural data and reproduce all statistical models reported in the manuscript.
Institutions
- University of HaifaHaifa, Haifa