[FieldTrip] Warning OPENEDF: Physical Minimum larger than Maximum\n

Katarina Bendtz katarina.bendtz at gmail.com
Wed Nov 18 20:20:13 CET 2020


Dear Simeon!

Thank you so much for your quick reply! I understand!

Do you think I can safely ignore this or should I try to find out which channels this applies to? That is, if the trigger channels are set to identical values, will this in some way compromise/change the data?

best,
Kat



Katarina Bendtz, PhD
Research Fellow
Kreiman Lab
Boston Children's Hospital
Harvard University

+1 (617) 390 45 16
3 Blackfan Circle 
Boston, USA




> On Nov 18, 2020, at 1:22 PM, Simeon Wong <simeon.wong at sickkids.ca> wrote:
> 
> Hi Katarina,
> 
> The fread command advances the file pointer. Therefore the 4 lines are reading consecutive values from the EDF file.
> https://www.mathworks.com/help/matlab/ref/fread.html?searchHighlight=fread&s_tid=doc_srchtitle#d122e421874:~:text=and%20positions%20the%20file%20pointer%20after%20the%20last%20value%20read <https://www.mathworks.com/help/matlab/ref/fread.html?searchHighlight=fread&s_tid=doc_srchtitle#d122e421874:~:text=and%20positions%20the%20file%20pointer%20after%20the%20last%20value%20read>
> 
> With that being said, some EDF export software (for better or for worse) set identical physical values if channels are switched off or for channels without physical units (ie. trigger channels or misc channels).
> 
> 
> 
> 
> All the best,
> Simeon
> 
> 
> <Outlook-gb44xqtx.png>
> Simeon Wong
> Ibrahim Lab
> Neurosciences & Mental Health
> 
> 686 Bay Street, Toronto ON  M5G 0A4
> P 416.813.7654  x303697
> 
> From: fieldtrip <fieldtrip-bounces at science.ru.nl> on behalf of Katarina Bendtz <katarina.bendtz at gmail.com>
> Sent: November 18, 2020 12:50
> To: fieldtrip at science.ru.nl <fieldtrip at science.ru.nl>
> Subject: [FieldTrip] Warning OPENEDF: Physical Minimum larger than Maximum\n
>  
> Dear experts:
> Me and my colleague at another university idependently I get this warning when we try to open an edf file:
> 
> Warning OPENEDF: Physical
>  Minimum larger than Maximum\n
> 
> 
> 
> I’m using fieldtrip 2020113. Looking at the source code 
>> 
>> https://github.com/fieldtrip/fieldtrip/blob/master/private/openedf.m <https://urldefense.com/v3/__https://github.com/fieldtrip/fieldtrip/blob/master/private/openedf.m__;!!D0zGoin7BXfl!tHOzBhC87IDZICVPmzh1QeJQI1pBz7wzlyRm7uCUqe_WlgHxjVh2sShWYk0yjAhO9UAo$>
> I read:
> 
> if (any(EDF.PhysMin >= EDF.PhysMax))
> 
> fprintf(2,'Warning OPENEDF: Physical Minimum larger than Maximum\n');
> 
> EDF.PhysMin = EDF.DigMin;
> 
>         EDF.PhysMax = EDF.DigMax;
> 
> end
> 
> but then a couple of lines up, I see both EDF.PhysMin and EDF.PhysMax, (and also EDF.DigMin and EDF.DigMax) being set to the same thing:
> 
> EDF.PhysMin= str2num(char(fread(EDF.FILE.FID,[8,EDF.NS],'char')'));
> EDF.PhysMax= str2num(char(fread(EDF.FILE.FID,[8,EDF.NS],'char')'));
> EDF.DigMin = str2num(char(fread(EDF.FILE.FID,[8,EDF.NS],'char')')); %
> EDF.DigMax = str2num(char(fread(EDF.FILE.FID,[8,EDF.NS],'char')')); %
> 
> So it is quite reasonable that I will get this warning. I’m puzzled. 
> 
> 1. What’s purpose of this warning?
> 2. Why are the variables set to the same value?
> 3. Can I safely ignore this warning?
> 4. Or is there something I misunderstood.
> 
> Thanks a lot,
> 
> Best,
> Kat
> 
> 
> 
> Katarina Bendtz, PhD
> Research Fellow
> Kreiman Lab
> Boston Children's Hospital
> Harvard University
> 
> +1 (617) 390 45 16
> 3 Blackfan Circle 
> Boston, USA
> 
> 
> 
> 
> 
> 
> This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies.
> _______________________________________________
> fieldtrip mailing list
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip <https://mailman.science.ru.nl/mailman/listinfo/fieldtrip>
> https://doi.org/10.1371/journal.pcbi.1002202 <https://doi.org/10.1371/journal.pcbi.1002202>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20201118/db93b784/attachment.htm>


More information about the fieldtrip mailing list