[FieldTrip] HardwareFilters attribute in save2bids

Schneider Christoph Christoph.Schneider at chuv.ch
Tue Sep 3 16:23:14 CEST 2019

Dear Community,

My name is Chris Schneider, and I am a postdoc working on EEG-based Brain-Computer Interfaces. Recently I discovered the extremely useful feature of transforming my datasets into a BIDS-compatible format for publishing the data on the OpenNEURO platform.

I have figured out how to set all the fields I want and need, except one: the "HardwareFilters" for the eeg.json files. In the data2bids.m file it is written that this field should contain a <<List of hardware (amplifier) filters applied or ideally  key:value pairs of pre-applied filters and their parameter values>>. In the meg section the explanation is more detailed <<List of temporal hardware filters applied. Ideally key:value pairs of pre-applied hardware filters and their parameter values: e.g., {"HardwareFilters": {"Highpass RC filter": {"Half amplitude cutoff (Hz)": 0.0159, "Roll-off": "6dB/Octave"}}}. Write n/a if no hardware filters applied.>>

I know that the structure in the final .json file should look like this:
[cid:image001.png at 01D56273.E266D9D0]

However, I was not successful in finding the right way of setting the attribute for the save2bids.m. I tried copy-pasting the example given for the meg, but it resulted in an error complaining about the colons not being strings. Then I converted the information into MATLAB key:value pairs, but this also resulted in a parsing error when preparing the json structure. Finally, I also tried to just pass it as a string, but then it gets written as one continuous string also in the json - and not in the requested key-value pairs (as in the image above).

I am out of ideas now short of implementing my own script for writing the json file. I would really appreciate to know if anybody successfully set this attribute in the save2bids.m , and if so, how. Thank you already very much in advance!



Christoph Schneider, PhD
Assistant de recherche
Laboratoire de Neurorééducation aigüe (LNRA)
Département des Neurosciences Cliniques (DNC)
Centre Hospitalier Universitaire Vaudois (CHUV)
Lausanne, Switzerland

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20190903/350d8b22/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 18265 bytes
Desc: image001.png
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20190903/350d8b22/attachment.png>

More information about the fieldtrip mailing list