From f7fbbd357133fd5c8a7ae1d364501aaf46c5bc15 Mon Sep 17 00:00:00 2001 From: Stefan Appelhoff Date: Tue, 24 Oct 2023 18:25:57 +0200 Subject: [PATCH] ENH: add ElectricalStimulation and *Parameters to MEEG --- src/schema/objects/metadata.yaml | 2 +- src/schema/rules/sidecars/eeg.yaml | 11 +++++++++++ src/schema/rules/sidecars/meg.yaml | 9 +++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/src/schema/objects/metadata.yaml b/src/schema/objects/metadata.yaml index 3e7d3e59a6..6d3e28dfc6 100644 --- a/src/schema/objects/metadata.yaml +++ b/src/schema/objects/metadata.yaml @@ -901,7 +901,7 @@ ElectricalStimulationParameters: display_name: Electrical Stimulation Parameters description: | Free form description of stimulation parameters, such as frequency or shape. - Specific onsets can be specified in the events.tsv file. + Specific onsets can be specified in the `events.tsv` file. Specific shapes can be described here in freeform text. type: string ElectrodeManufacturer: diff --git a/src/schema/rules/sidecars/eeg.yaml b/src/schema/rules/sidecars/eeg.yaml index f74da26f7b..7a7252d69b 100644 --- a/src/schema/rules/sidecars/eeg.yaml +++ b/src/schema/rules/sidecars/eeg.yaml @@ -43,6 +43,7 @@ EEGInstitutionInformation: InstitutionAddress: recommended InstitutionalDepartmentName: recommended +# Specific EEG fields MUST be present EEGRequired: selectors: - datatype == "eeg" @@ -57,6 +58,7 @@ EEGRequired: PowerLineFrequency: required SoftwareFilters: required +# Specific EEG fields SHOULD be present EEGRecommended: selectors: - datatype == "eeg" @@ -79,6 +81,15 @@ EEGRecommended: HardwareFilters: recommended SubjectArtefactDescription: recommended +# Specific EEG fields MAY be present +EEGOptional: + selectors: + - datatype == "eeg" + - suffix == "eeg" + fields: + ElectricalStimulation: optional + ElectricalStimulationParameters: optional + # General fields EEGCoordsystemGeneral: selectors: diff --git a/src/schema/rules/sidecars/meg.yaml b/src/schema/rules/sidecars/meg.yaml index 0b624e1559..a989d40f9f 100644 --- a/src/schema/rules/sidecars/meg.yaml +++ b/src/schema/rules/sidecars/meg.yaml @@ -107,6 +107,15 @@ MEGRecommended: AssociatedEmptyRoom: recommended HardwareFilters: recommended +# Specific MEG fields MAY be present +MEGOptional: + selectors: + - datatype == "meg" + - suffix == "meg" + fields: + ElectricalStimulation: optional + ElectricalStimulationParameters: optional + # Specific EEG fields # NOTE: I'm not sure if "EEG is present" is enough to indicate simultaneous EEG/MEG. MEGwithEEG: