From 839d63727e560e5794ae2303a42cadebdd765a6a Mon Sep 17 00:00:00 2001 From: schoffelen <1517611+schoffelen@users.noreply.github.com> Date: Mon, 13 Apr 2026 14:31:41 +0200 Subject: [PATCH 1/3] changed docstring for consistency + typo --- loadbvrf.m | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/loadbvrf.m b/loadbvrf.m index a7e524e..4c19ba6 100644 --- a/loadbvrf.m +++ b/loadbvrf.m @@ -2,10 +2,10 @@ % readBVRF() - Read data saved in the Brain Vision Recorder format. % % Usage: -% >> [hdr, data, markers] = readBVRF(hdrFile, verbose); +% >> [hdr, participantId, data, channels, markers, impedances] = readBVRF(hdrFile, verbose); % % Inputs: -% hdrFile - Hader file (bvrh). Data (.bvrd) and marker (bvrm) files should be in the same folder. +% hdrFile - Header file (bvrh). Data (.bvrd) and marker (bvrm) files should be in the same folder. % sampleRange - [first, last] samples that define the interval to read. Enter [] to read all samples. % flagMetadata - Loads only the header metadata. % verbose - Optional input. Set to true to display messages. @@ -294,4 +294,4 @@ end end end -end \ No newline at end of file +end From bbb8c38de833ce177b41dca4c7253b2801fc19a2 Mon Sep 17 00:00:00 2001 From: schoffelen <1517611+schoffelen@users.noreply.github.com> Date: Mon, 13 Apr 2026 15:53:25 +0200 Subject: [PATCH 2/3] critical fix for correct reading if sampleInterval~=[] --- eeg_loadbvrf.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eeg_loadbvrf.m b/eeg_loadbvrf.m index e6411c4..f0ceb7b 100644 --- a/eeg_loadbvrf.m +++ b/eeg_loadbvrf.m @@ -230,7 +230,7 @@ fid = fopen(dataFile, 'r'); fseek(fid, opt.sampleInterval(1) * nChannels * nBytes, 'bof'); - vec = fread(fid, opt.sampleInterval(2), precision, 'ieee-le'); + vec = fread(fid, opt.sampleInterval(2) * nChannels, precision, 'ieee-le'); fclose(fid); n = length(vec); From 32f13c9731f426c82a908103b4dc28e1981ed099 Mon Sep 17 00:00:00 2001 From: schoffelen <1517611+schoffelen@users.noreply.github.com> Date: Mon, 13 Apr 2026 15:57:35 +0200 Subject: [PATCH 3/3] reverted docstring, changes are in other PR --- loadbvrf.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/loadbvrf.m b/loadbvrf.m index 4c19ba6..698dd88 100644 --- a/loadbvrf.m +++ b/loadbvrf.m @@ -2,10 +2,10 @@ % readBVRF() - Read data saved in the Brain Vision Recorder format. % % Usage: -% >> [hdr, participantId, data, channels, markers, impedances] = readBVRF(hdrFile, verbose); +% >> [hdr, data, markers] = readBVRF(hdrFile, verbose); % % Inputs: -% hdrFile - Header file (bvrh). Data (.bvrd) and marker (bvrm) files should be in the same folder. +% hdrFile - Hader file (bvrh). Data (.bvrd) and marker (bvrm) files should be in the same folder. % sampleRange - [first, last] samples that define the interval to read. Enter [] to read all samples. % flagMetadata - Loads only the header metadata. % verbose - Optional input. Set to true to display messages.