Merging two 32-channel devices into a 64-channel recording

Explore Signals can combine recordings from two Explore devices into a single recording. Two 32-channel Explore Pro devices recorded together produce one unified 64-channel file.

Merging is offline. You record with both devices as usual, then combine the resulting files afterwards.

The two devices must be time-synchronized with Mentalab Hypersync during recording. Without it, each device timestamps its samples against its own independent clock, so Explore Signals has no common time base to align them on, and the merged file will not represent a single moment in time.

Before you start

Check the following before merging:

  • Both devices were synchronized with Mentalab Hypersync for the whole session.

  • Both devices used the same sampling rate. Explore Signals refuses to merge recordings whose sampling rates differ.

  • The two recordings overlap in time. Only the overlapping period is merged. If they do not overlap at all, the merge fails.

  • You have the right files. Either the two _ExG.csv recordings, or a single .xdf file containing both devices' streams.

How the merge works

Explore Signals does not resample both recordings onto a new common clock. Instead:

  1. It finds the window in which both recordings were running, and discards everything outside it.

  2. It takes the first recording, File A, and keeps its timestamps and samples exactly as they are. This becomes the time base for the merged file.

  3. For every sample time in File A, it takes the sample from File B whose timestamp is closest.

  4. It stacks the two sets of channels into one file.

Two consequences are worth knowing:

  • File A is preserved sample for sample. File B is matched onto the sample times of File A by nearest-neighbour selection, not interpolated, so each of its samples can shift by up to half a sample period.

  • Which file you choose as File A therefore determines whose timestamps survive. If one device matters more for your analysis, or if one recording is cleaner, make that one File A.

Merging two CSV recordings

To merge two _ExG.csv recordings:

  1. Navigate to:

    File > Convert > Merge Recordings
  2. Under Input format, select CSV (two files).

  3. Click Browse next to File A and select the first _ExG.csv file.

  4. Click Browse next to File B and select the second _ExG.csv file.

  5. Click Browse next to Output folder and choose where the merged files should be written.

  6. Enter an Output base name. This is the name the merged files are built from. If you leave it empty, Merged is used.

  7. Leave Merging strategy set to Nearest sample.

  8. Optionally add sync-status markers. See the section below.

  9. Click Merge.

The Merge button stays disabled until the required fields are filled in. If a setting is not valid, the dialog shows the reason in red above the buttons.

The Merge Recordings dialog in CSV mode with both input files, an output folder, and an output base name set.
The Merge Recordings dialog, set up to merge two CSV recordings

File requirements

Both inputs must be ExG recordings, meaning files whose names end in _ExG.csv. Explore Signals rejects other files.

Explore Signals also reads the following files from the same folder, when they are present:

  • _Meta.csv — used to read the sampling rate. Without it, the sampling rate is estimated from the timestamps.

  • _Marker.csv — event markers, merged into the output.

  • _ORN.csv — motion sensor data, merged into the output.

For this reason, keep each recording together with its sibling files rather than moving the _ExG.csv file on its own.

Merging from an XDF recording

If you recorded both devices into a single .xdf file through LSL, select XDF (single file) under Input format. The dialog then asks for one XDF file instead of the two CSV files.

The file must contain exactly two Explore ExG streams. If it contains a different number, Explore Signals reports how many it found and stops.

The remaining settings work the same way, and the output is written as CSV files exactly as in the CSV workflow.

The Merge Recordings dialog in XDF mode, showing a single XDF file field.
The same dialog in XDF mode, asking for one file instead of two

What the merge produces

Using the default output base name Merged, the merge writes:

File Contents

Merged_ExG.csv

The unified recording. One TimeStamp column followed by all channels from both devices, for example 64 channels from two 32-channel devices.

Merged_Meta.csv

Metadata for the merged recording, including the sampling rate and the combined channel list. The Device field records which two devices were merged.

Merged_Marker.csv

Event markers from both recordings, restricted to the overlapping window.

Merged_ORN.csv

Motion sensor data from both devices. Written only when both inputs have an _ORN.csv file.

Channel names

Channels keep their original names with the device ID appended, so you can always tell which device a channel came from. Two 32-channel devices produce 32 columns carrying the first device’s ID, followed by 32 columns carrying the second device’s ID.

If both recordings come from the same device ID, Explore Signals appends _A and _B instead, so that the column names stay unique.

Markers are labelled the same way, with the device ID in front of the marker code.

Adding sync-status markers

Mentalab Hypersync records a Session Status file describing when your devices were synchronized during the session. Attaching it to the merge adds markers showing where the synchronization held and where it did not.

To add them, in the Session Status (Optional) section of the dialog:

  1. Select the checkbox for adding sync status markers. The fields below it become available.

  2. Choose Single File if you want to select the Session Status file directly, or Folder to point at the folder containing it.

  3. Click Browse and select the file or folder.

Explore Signals then adds a marker to Merged_Marker.csv at each point where a device’s sync status changed:

  • Good Sync — the device was synchronized from this point on.

  • Bad Sync — the device had drifted out of sync from this point on.

Each marker is labelled with its device ID, and only transitions inside the merged window are included. Adding markers does not shorten the recording.

Use these markers to find and exclude stretches where the two devices were not reliably aligned. This matters for a merged recording: if the devices drifted apart, channels from the two devices no longer describe the same moment in time.

Session Status files are named SessionStatus<date>_<time>.csv, or session_status_<date>_<time>.csv in older versions.

If the Session Status file cannot be read, or contains no transitions inside the merged window, Explore Signals reports this and completes the merge without sync markers. The merged data itself is unaffected.

Using the merged recording

The merged recording is an ordinary Explore Signals recording. You can load Merged_ExG.csv through File > Open and then visualize, filter, and analyze it like any other file.

A merged 64-channel recording loaded in Explore Signals, scrolled to the point where the channels of the first device end and those of the second begin.
A merged 64-channel recording, scrolled to the point where one device’s channels end and the other’s begin

To work with the recording in other software, export it to .bdf or convert it to an EEGLAB dataset. See the Usage page for both.

Troubleshooting

Message or symptom What to do

Both files must have the same sampling rate

The two devices recorded at different rates. Explore Signals cannot merge them. Re-record with matching sampling rates.

The two recordings do not overlap in time

The devices were not recording at the same time, or the files come from different sessions. Check that both files belong to the same Hypersync session.

File A must be an ExG recording

You selected a file that is not an _ExG.csv recording, such as a _Meta.csv or _ORN.csv file. Select the ExG file instead.

Expected exactly 2 Explore ExG streams in the XDF

The .xdf file contains a different number of Explore ExG streams. Merging supports exactly two.

Could not determine sampling rate

The _Meta.csv file is missing and the sampling rate could not be derived from the timestamps. Keep the recording together with its sibling files.

No Merged_ORN.csv was written

Motion data is merged only when both recordings have an _ORN.csv file. If either is missing, the rest of the merge still completes.

The Merge button stays greyed out

A required field is still empty. Check that both input files, the output folder, and the output base name are set. If sync-status markers are enabled, a Session Status file or folder is required too.

The merged file is shorter than either recording

This is expected. Only the window in which both devices were recording is kept.

Limitations

  • Merging combines exactly two recordings. To combine more devices, merge in stages, using the output of one merge as an input to the next. Check the result carefully, because each stage aligns onto a new time base.

  • Inputs must be .csv or .xdf. Recordings in .bdf or .edf cannot be merged directly.

  • The merged output is always written as CSV files, regardless of the input format.

  • Samples from File B are matched by nearest neighbour rather than interpolated. Nearest sample is currently the only merging strategy.

For more information or support, contact support@mentalab.com.