Skip to content

Commit 2f8d661

Browse files
committed
update specification of electrodes.tsv
1 parent abb1dd6 commit 2f8d661

File tree

2 files changed

+79
-28
lines changed

2 files changed

+79
-28
lines changed

src/modality-specific-files/electromyography.md

Lines changed: 34 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -284,21 +284,29 @@ and a guide for using macros can be found at
284284
-->
285285
{{ MACROS___make_filename_template("raw", datatypes=["emg"], suffixes=["electrodes"]) }}
286286

287-
File that gives the location of EMG electrodes.
288-
Descriptions of electrode location in `*_electrodes.tsv` files MUST reflect the process
289-
used by the researcher(s) when placing electrodes, electrode locations MUST NOT simply
290-
give the name of the targeted muscle.
291-
For example, EMG electrode sites may be chosen by visual reference to target muscles,
292-
by palpation of the skin to locate target muscles, by functional localization
293-
(temporary electrode placement at several sites during prescribed behavior,
294-
until a site yielding strong EMG signal is found), or by measured distances
295-
(either absolute or proportional) in a coordinate system defined by skeletal landmarks.
296-
Electrode location descriptions MAY refer to reference texts in regard to electrode placement,
297-
such as SENIAM.
298-
Measured coordinates are expected to conform to the `EMGCoordinateSystem` and
299-
`EMGCoordinateUnits` fields in `*_coordsystem.json`.
300-
**If measured coordinates are provided in an `*_electrodes.tsv` file, a
301-
[`*_coordsystem.json`](#coordinate-system-json-_coordsystemjson) file MUST be specified as well**.
287+
File that gives the measured location, size, and other properties of EMG electrodes.
288+
If an `*_electrodes.tsv` file is specified, a `*_coordsystem.json` file MUST be specified
289+
as well.
290+
291+
When 3D electrode locations are digitized in situ, the origin, orientation, and measurement
292+
unit of the coordinate system MUST be recorded in cartesian coordinates according to the
293+
`EMGCoordinateSystem` and `EMGCoordinateUnits` fields in `*_coordsystem.json`,
294+
as described in the [Coordinate Systems Appendix](../appendices/coordinate-systems.md).
295+
In such cases, `EMGCoordinateSystem` SHOULD be specified as `Other` and the
296+
`EMGCoordinateSystemDescription` SHOULD contain a description of the origin of the 3D
297+
coordinate system.
298+
299+
When accurate 3D locations are unavailable, 2D locations may be provided to define the
300+
geometry of an electrode grid or group, prior to anatomical placement.
301+
See the [`electrodes.tsv` example](#example-electrodestsv) section for an example.
302+
In such cases, `EMGCoordinateSystem` SHOULD be specified as `Other` and the
303+
`EMGCoordinateSystemDescription` SHOULD contain a description of the origin of the 2D
304+
coordinate system (for example, "origin at the center of the grid" or "origin at the
305+
center of the electrode in the lower-left corner of the grid, when oriented with the
306+
leads downward").
307+
In such cases, the description in the `EMGPlacementScheme` field of `*_emg.json` MAY
308+
refer to the origin of that 2D coordinate system in describing the placement of the grid.
309+
302310
The order of the required columns in the `*_electrodes.tsv` file MUST be as listed below.
303311

304312
<!-- This block generates a columns table.
@@ -309,9 +317,9 @@ and a guide for using macros can be found at
309317
-->
310318
{{ MACROS___make_columns_table("emg.EMGElectrodes") }}
311319

312-
The [`acq-<label>`](../appendices/entities.md#acq) entity SHOULD be used to indicate simultaneous
313-
acquisition of data from multiple EMG devices, in cases where the devices store data in separate
314-
data files.
320+
The [`acq-<label>`](../appendices/entities.md#acq) entity MUST be used to indicate
321+
simultaneous acquisition of data from multiple EMG devices, in cases where the devices
322+
store data in separate data files.
315323
For example:
316324

317325
<!-- This block generates a file tree.
@@ -343,18 +351,16 @@ If electrodes are repositioned, it is RECOMMENDED to use multiple sessions to in
343351

344352
### Example `*_electrodes.tsv`
345353

346-
See also the corresponding [`electrodes.tsv` example](#example-channelstsv).
354+
Example `*_electrodes.tsv` for a 2 by 2 grid of EMG electrodes with 2.5 mm electrode diameter
355+
and 10 mm inter-electrode distance.
347356

348-
<!-- TODO not yet updated after copy/paste from EEG -->
357+
<!-- TODO should we demo other columns here too? Should we add ground/ref electrodes? -->
349358
```Text
350-
name x y z type material
351-
VEOG+ n/a n/a n/a cup Ag/AgCl
352-
VEOG- n/a n/a n/a cup Ag/AgCl
353-
FDI+ n/a n/a n/a cup Ag/AgCl
354-
FDI- n/a n/a n/a cup Ag/AgCl
355-
GND -0.0707 0.0000 -0.0707 clip-on Ag/AgCl
356-
Cz 0.0000 0.0714 0.0699 cup Ag/AgCl
357-
REF -0.0742 -0.0200 -0.0100 cup Ag/AgCl
359+
name x y diameter
360+
001 0.0 0.0 2.5
361+
002 10.0 0.0 2.5
362+
003 0.0 10.0 2.5
363+
004 10.0 10.0 2.5
358364
```
359365

360366
## Coordinate System JSON (`*_coordsystem.json`)
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
EMGChannels:
3+
selectors:
4+
- datatype == "emg"
5+
- suffix == "channels"
6+
- extension == ".tsv"
7+
initial_columns:
8+
- name__channels
9+
- type__channels
10+
- units
11+
columns:
12+
name__channels: required
13+
type__channels: required
14+
units: required
15+
description: optional
16+
sampling_frequency: optional
17+
reference__emg: optional
18+
low_cutoff: optional
19+
high_cutoff: optional
20+
notch: optional
21+
status: optional
22+
status_description: optional
23+
index_columns: [name__channels]
24+
additional_columns: allowed_if_defined
25+
26+
EMGElectrodes:
27+
selectors:
28+
- datatype == "emg"
29+
- suffix == "electrodes"
30+
- extension == ".tsv"
31+
initial_columns:
32+
- name__electrodes
33+
- x
34+
- y
35+
- z
36+
columns:
37+
name__electrodes: required
38+
x: required
39+
y: required
40+
z: optional
41+
type__electrodes: recommended
42+
material: recommended
43+
impedance: recommended
44+
index_columns: [name__electrodes]
45+
additional_columns: allowed_if_defined

0 commit comments

Comments
 (0)