EMG 3.2 Manual

Introduction

Welcome, and thank you for taking the time to read this manual for the MindWare Electromyography (EMG) 3.2 analysis application. With every release of the analysis applications, we aim to include new and innovative tools and algorithms to improve the data analysis experience. These are often driven by user feedback and always grounded in strong scientific principles.

It is our sincerest hope that the use of this application leads to better, more productive, more enjoyable research in your field.


 

What’s New in 3.2

  • General
    • Official Windows 10 support
  • Setup
    • Streamlined events and modes setup with new options available
    • Add multiple event sources to use events from a variety of systems
    • Show events for reference when analyzing in Time mode
    • More flexible event-based analysis, including the option to split an event-based segment into multiple smaller segments
    • Improved Multi-Event (previously “Event to Event”) analysis support, allowing for quicker analysis of multiple event combinations
    • Improved AcqKnowledge file read – files no longer need to be re-scaled or re-sampled before opening in MindWare
    • Streamlined channel mapping emphasizes the use of edit files
    • New edit file format stores important settings needed to reproduce the edited data. These settings are automatically recalled when the edit file is loaded
  • Analysis
    • New EMG startle mode
      • Specify baseline and analysis windows based on events
      • Group events by event source or other descriptors (such as valance)
      • Detect response onset and peak
      • Mark trials as accepted, no response, and rejected
      • Average across multiple trials of the same condition to obtain response probability and average response amplitude/magnitude
    • View all EMG signals side by side for comparison, or individually
    • Keyboard shortcuts for writing segments and searching through the file for points of interest such as an unwritten segment or artifact
  • Editing
    • Undo/redo edits
    • Save edits as you analyze instead of just when you are done
    • New channel display options
    • Edit all channels simultaneously, or apply edits to each channel individually
    • Keyboard shortcuts for selecting graph tools and scrolling through data
    • Startle mode – manually adjust onset and peak location
  • Output
    • Write Excel output files without having Excel installed
    • Edit statistics worksheet contains point distribution and data edits summary
    • Open an existing output for a given data file during analysis to continue writing to it in a new session. Automatically detect which segments have already been written

 

General Concepts

Before getting started, let’s go over a few concepts which will be key to understanding how the application works. We will be referring to these items throughout the guide in various sections, so get to know them before proceeding.

Types of Files

You will be working with a variety of file types in this application and it is important to be able to differentiate between them.  Later in the guide, you will see where the various files are used.

Data

Data files contain the dataset you intend to analyze. These are the files you will open when the application starts up, and anytime you want to load a new dataset. Several popular file formats are supported, which will be discussed in detail later.

Edit

The analysis applications strictly adhere to a policy to never alter the original data file that is loaded. Any changes you make to the signals and their annotations are stored in a separate file called an edit file.

These files also store some key configuration information, so that when you view your edits you can be sure the proper settings are being applied.

Edit files created in EMG3.2 have the file extension “.edmg2″. They are by default stored in a subdirectory of the data files directory called “edit data”, but can be stored anywhere you choose.

User Preferences

These files are created automatically when either:

  1. The data file is created in BioLab or
  2. The data file is opened in a MindWare analysis application

They follow the naming convention:

Data File Name_userpreferences.cfg

and are stored in the same directory as the data file.

As long as these files are stored in the same directory as their corresponding data file, certain file-specific settings will be preserved between uses of the application and when the file is opened in other analysis applications.

Configuration

The analysis applications contain many configurable settings, and these settings may vary between studies, files, or subjects. When multiple researchers are using the application concurrently, or when you simply want to backup your settings for peace of mind, saving a configuration file is the way to do it. These files can then be loaded to restore settings to a known state before proceeding with analysis. Configuration files have the “.emgcfg2” file extension.

Output

Statistics derived from analysis can be written out to a file for use in higher level statistical analysis packages. The output is stored in Excel (.xlsx) format.

Channels & Signals

Data files consist of multiple channels, each of which was used to acquire a particular signal. In the analysis application, you will have to map each of these channels to a signal type, which will dictate how the application uses them. Throughout the guide/application, these terms are used interchangeably to describe the same thing.

Events

Events are specific points of interest in a data file. You may want to base your data analysis procedures on these events (for example, when these events indicate the start/end of a particular task), or they may just be for reference to explain a change in physiology/subject behavior. These are most commonly created during data collection but are sometimes generated post-acquisition depending on your workflow/tools used.

Event Sources

Events can come from a variety of sources. They may be stored as special time points in the data file itself, derived from a channel, or read from an auxiliary file from another system used during data acquisition. The specific event sources that are supported in the application will be discussed in more detail later.

Segments

Data files are divided into segments for analysis purposes. These segments can be defined in logical ways based on your experimental protocol using either time or events. At any given time, only a single segment is visible on the analysis screen.


 

Launching the Application

To launch the EMG application, double-click the shortcut on your desktop:

Or navigate to the MindWare folder from the Start menu and select EMG Analysis 3.2

Be sure to insert your software key before launching the application!

A quick note on licensing

MindWare applications are licensed through the use of a Software Key, the small silver USB key that you received with the purchase of the software.

MindWare Software Key
MindWare Software Key

These keys can hold the license to multiple applications, or to a single application, depending on how the software was purchased. To view which licenses are on your software key, you can use the License Manager.

A software key with a license to run EMG 3.2 must remain plugged into the computer throughout the use of the application. If the software key is not detected, you will receive an error message:

The options at this point are to insert the software key, exit the application, or proceed in Demo Mode. Which brings us to our next quick aside…

A quick note on Demo Mode

If you have just downloaded the application to try it out – welcome, and thank you for taking the time to evaluate this application! You don’t need a software key to unlock the full capabilities of the software for evaluation purposes, with one caveat – it will only work with specific demonstration files.

Some demo files are automatically installed with the application, and when in Demo Mode, the demo data folder (My Documents/MindWare/EMGExamples) will automatically open when prompted to select a file. You can also go to Help>>Download Demo Data… on the Setup screen to download additional example files.

When you find you can no longer survive without this application aiding you in your research endeavors, feel free to visit our online store or contact a MindWare sales representative ([email protected]) to purchase a full license.


 

Selecting a file for analysis

Once the application is running, the first thing to do is to select a data file for analysis.

Navigate to the data file of your choosing, and either double-click it or highlight it and press OK. Many popular data file types are supported:

.mwx/.mwi

This is the file type that is written by Mindware BioLab 3.1 and newer. The applications are designed to work seamlessly with this file format and there are many advantages to using these files:

  • Data is automatically scaled to the appropriate units, when possible
  • Events are stored directly in the file (we’ll cover this more in a bit)
  • Video files recorded in BioLab are automatically selected for use

Note that when working with these files, the “.mwi” is opened from the file dialog, but both are required for analysis and must be stored in the same directory.

.mw

This is the file type that was written by MindWare BioLab 3.0 and earlier. These files lack some of the additional information stored in MWX/MWI files.

.acq

These are BioPac AcqKnowledge data files. They must be stored as a “Windows AcqKnowledge 3 Graph” before being used for analysis.

.edf

This is the European Data Format, a popular open source file format. Visit the official website for more information on this file format.

.bdf

This is the BioSemi data format, an offshoot of the EDF file format but used exclusively by BioSemi acquisition hardware.

Other

Even if your data file is not on this list, there is a good chance you can still analyze it! Check out this article on the ASCII-MW converter for more information.

Want to see your preferred file format read directly? Let us know!


 

Channel Mapping

After selecting a data file for analysis, the application will prompt you to map the channels to the signal types that the application will use.

 

Recall that a channel is simply a container in the data file for a particular signal, but at this point, the precise signal type is unknown to the EMG application. Ideally, the channel has been named such that it is obvious what signal type it contains, so this step should be easy.

 

The EMG application can be useful for analyzing data collected from various muscle groups or accelerometer data (or anything that is indicative of movement). Regardless of how the channel is mapped, analysis will be performed the same.

Edit Files

We aren’t quite done with the Channel Mapping screen yet. This is also where you will specify the edit file you intend to load.

When a data file is opened for the first time, the edit file will default to New, since no edits exist yet for this dataset. Once a dataset is edited and opened for the second time, the last used edit file will automatically be loaded.

When an edit file is loaded, you will notice that the channel mapping is done for you, set the way it was when the edit file was created.

This is because the channel mapping is stored in the edit file, and automatically applied to ensure the edits are applied to the correct channels in the file. There are a few other settings which will also be affected in this way, which we will cover a little later.

If you wish to open a different edit file, click the browse button next to the Edit File path

To start a new edit file from scratch, make sure the mode is set to New

Specifying new Edit File

Modifying the channel map

If you want to load a new edit file, or if you made a mistake in your original channel mapping, you can always change it by going to File>>Map Channels… or use the hotkey Ctrl+M on the Setup screen.

Setup Screen

The setup screen is where everything in the application is configured, including the way the data is segmented, specific algorithm settings, video playback settings, and much more.

Some of these settings are available across all MindWare analysis applications, so they may look familiar. Others are specific to the EMG application. This section of the guide will cover all of these options in detail, starting with Events and Modes.

Events & Modes

As mentioned earlier, data analysis is always performed in segments – portions of time defined either by specific time intervals or by events. The way the data is segmented during analysis can have a significant impact on the results, and segmentation must be considered carefully before proceeding with analysis. The settings on the Events & Modes tab are used to define these segments. There are four main modes available in EMG 3.2, which are selected from the mode selector:

Let’s start by examining the left of the screen, where there are two lists – Event Sources and Events.

Event Sources

Event sources represent all available events that could occur within a data file. They are displayed in a hierarchical manner, and it is common (especially when using MWX/MWI files) to see nested event sources, which help give further clarity to the origin and meaning of an event. It is possible to use both Event Sources and Events to define data segments.

Note: These lists represent all available event sources and events, but they do not all necessarily need to be used for analysis. We will talk about how to use these later.

Now let’s go over how Event Sources are loaded into the application.

Default Event Sources

By default, any event sources that are stored within the currently opened data file will automatically populate in the event sources list. You can tell an event source is default a couple of ways:

  • It cannot be removed from the list:

 

  • The first level in the event source hierarchy is the name of the data file opened:

Note: Currently, only MWX/MWI files and ACQ files are supported as defaults

Adding an Event Source

To add an event source, press the Add button below the Event Sources list:

A new window will appear, prompting you to select the type of event source you would like to add:

Note: You will typically only have a couple of these, but you can add as many as you require

There are several types of event sources supported:

MindWare Event File

The MindWare Event file is a text-based format used by BioLab 3.0 and earlier. It is also quite useful as an intermediary file format to bring external events into the analysis applications.

If a properly named MindWare Event file is identified, it will automatically populate the file path and select the Default? option. A properly named MW event file uses the following naming convention:

Data file name minus extension_event.txt

And is stored in the same directory as the data file. Versions of BioLab that wrote this event file (3.0 and earlier) name the files this way automatically, but if you are using the MW Event file format to bring in events from an unsupported 3rd party system, make sure you name them well to be automatically identified. Otherwise, ensure Default? Is unchecked and press the Browse button to select a file with a different naming convention.

There are two types of MindWare event files – Absolute Time and Relative Time. Absolute Time is based on the actual wall clock time of the event and Relative Time is based on time elapsed from the start of the acquisition. Depending on the way the events are stored in the file, the Type will need to be updated accordingly.

You also have the option of offsetting events in the file by a specific time constant (in fractional seconds).

This is particularly useful for bringing in events from a 3rd party system which was not started in sync with physiology data collection.

If you attempt to open a MindWare Event file that is not properly formatted, you will receive an error.

If this happens, check your event file and try again.

Noldus Observation File

MindWare applications support integration with Noldus Observer XT during both data acquisition and analysis. Once an observation has been completed, you can bring the observation data (in .txt format) into the analysis applications via a Noldus Observation file. This type of event source behaves in the same way as a MindWare Event file, but with a slightly different default naming convention:

Data file name minus extension_observation.txt

For more information on exporting these observations from Noldus Observer, see this article.

Digital Event Channel

Events can also be derived from channels within the data file. Most commonly, these channels represent either individual digital lines used to capture event markers from integrated systems during data collection, or a summary representation of a group of these digital lines. When detecting events from a channel such as this, the application is looking for changes in the value of the channel that are maintained for some duration of time.

The following settings are available, and should be set based on the system used to generate the digital events:

  • Channel name – the channel on which to search for events
  • Pulse direction – look for changes in the positive direction, the negative direction, or both
  • Pulse width – how long a change needs to persist in the channel before it is considered an event. This can help prevent multiple events from being detected when there is noise in the digital line

Note: In BioLab 3.0 and greater, digital events are also stored as events in the data file (or event file) and therefore it is not necessary to load them this way.

Editing an Event Source

To edit the details of an event source, highlight any item within the hierarchy and press Edit.

Note: Default event sources cannot be edited

Removing an Event Source

Much like editing event sources, to delete simply highlight any item in the hierarchy and press Remove

Note: Default event sources cannot be removed. Also keep in mind that even though an event source is listed here, that does not necessarily mean it is being used for analysis.

Some caveats on how event sources are loaded

First, any default event sources will be loaded. Next, if any event sources are stored in the User Preferences file, those will be loaded. These event sources reflect those chosen the last time the file was analyzed. If there are no event sources in the User Preferences file, the application will try to load whatever event sources were used with the last data file that was opened. If these event sources are not available for the current data file, you will receive a warning stating such:

Event sources which are dependent on the data file name (such as MW Event and Noldus Observation files) will automatically update to search for the current data file default path. If you are not using the default naming convention for these files, you will need to specify them for each new data file you analyze.

Events

Events are the specific instances of event sources, occurring at a given time. The event list consists of pairs of an event source name and the time at which it occurred. Events can be selected by left-clicking them. Select multiple events by Ctrl+click. Select a range of events by selecting the first event, and then Shift+click the last event.

Filtering the event list

When an event list is large, it may be useful to filter the list by the event name to isolate the events of interest. There are a few ways you can do this:

Manual Entry

Begin typing the desired event name into the Filter box, and the events which qualify will remain visible in the list:

Specific events in the event source hierarchy can be filtered directly by separating the levels of the hierarchy with the “:” character, as shown in this example:

Drag and drop Event

To find all occurrences of a specific event, left-click it in the events list and, while holding the mouse button, begin to drag it. You will notice how the Filter text box is highlighted, and the selected event is floating outside the list:

Drag the event into the Filter box, at which point it will turn green to indicate it is ready to be dropped:

Release the left click to automatically filter based on that event:

Drag and Drop Event Source

The same action can be done on an event source at any level in the hierarchy. When this is done, events will be filtered both by name and source:

Time Mode

Time mode is used for (you guessed it) segmenting your data in fixed time intervals. The timeline indicates the currently selected start and end time for analysis. Individual segments are notated with grey lines along the timeline, the duration of which is defined by Segment Time.

To modify the start/end time of analysis, uncheck File Start or File End and drag the start/end point to the desired time (or manually input a start or end time):

Using events in Time mode

There are some opportunities to use events to assist in analyzing the data in Time mode, even if the segments aren’t defined directly by them. First, there is an option to Show Events:

When this is checked, events will be shown in the data segments as they occur, which can be useful for reference when determining the cause of physiologic changes or noise in the data.

The second way events can be used is to help define a start and end time for analysis. To start/end analysis at a certain event, left-click that event in the Events list and drag it into the Start Time or End Time field.

This will automatically adjust the start/end time to that event time.

If you are interested in learning other, more powerful ways to use events, continue on to the next section on Event mode.

Event Mode

Event mode allows you to use pre-defined, specifically labeled time points in the data file to define your segmentation. Use of events can be very powerful for data analysis and can be a serious time saver over constantly adjusting Time mode settings to view specific time points of interest. These events are typically stored during data acquisition, but can also be entered post-acquisition using applications such as BioLab.

Using the timeline

At the top is the segment timeline, but rather than being based on the start and end of the data file, it is now based on the occurrence of an event, indicated by the black vertical line in the timeline:

The two sliders on the timeline can be dragged on either side of the event, and frame what time around the event is of interest:

There are many different ways you can view your data using the timeline.

Pre Event

To look strictly pre-event, lock the end slider to the event by checking Zero next to the end time and drag the start slider to the left of the event, or enter a time manually. Keep in mind that since we are looking at the time relative to an event, the start time will be a negative number.

Post Event

Similarly, lock the start slider to the event by checking Zero next to the start time and drag the end slider to the right of the event, or enter a time manually to look strictly post-event.

Pre and Post Event (single segment)

To look at some amount of time before and after each event in a single segment, make sure both sliders aren’t locked to the event and drag them where you desire on either side of the event.

Pre and Post Event (multiple segments)

To look at pre and post-event times in their own segments, check the Split at Event option. This will cause the pre and post event portions of the timeline to appear in different colors. 

Segment based on, but not including an event

To look at a segment that is based on the time of an event, but does not include the actual event, drag both sliders to either side of the event in the timeline.

Events to Use

As mentioned earlier, just because an Event Source/Event is listed to the left does not mean it will be used for analysis. Rather, they must be selected from that list explicitly. There are 3 ways events can be selected: All, Event, and Event Source.

All

All events in the event list will be used for analysis:

Event

Use event-based selection when there are specific instances of events that you want to analyze based on. Any of the events in the Events list can be selected for use. Ctrl-click to select multiple events, and Shift-click to select a range of events.

Adding Events to Use

To add events to this list, drag and drop events from the Events list into the Events to Use list. This is done by left-clicking on the desired events in the Events list and dragging those events out of that list and into the Events to Use list.

When the Events to Use list is highlighted in green, that means the event can be dropped. Release the mouse button to add the event to the list.

Events will be sorted in chronological order automatically as they are added to the list.

Removing Events to Use

To remove events from this list, select the event(s) to remove and drag them anywhere outside of the Events to Use list. The list will be highlighted red to indicate events will be removed.

Release the mouse button to remove the event from the list:

Event Source

The same can be done for event sources. When analyzing based on a source, all instances of a given event source will automatically be used for analysis. The right-most column in the list indicates how many instances of that source will be used.

Adding Event Sources to Use

Similar to Event-based selection, drag and drop event sources from the list on the left to use them for analysis:

Notice how the “Demo Events” event source contains multiple events, indicated by the rightmost column in the table.

If an event source at a higher level in the hierarchy is chosen, all occurrences of event sources below it will also be selected for analysis:

Any entries which were already in the event sources to use list will be replaced by the higher level event source.

Removing Event Sources to Use

This is done the same way as removing an event from the list – select the event source(s) to remove, drag the selection outside of the list,

and releasing the mouse button to remove from the list.

Switching between selection modes

When switching between the selection modes, it is possible to preserve the events currently selected for use in the new mode:

When events selections are preserved, the new selection mode will already contain the events used in the previous mode. If events are not preserved, the list will be empty in the new mode.

Split into Segments

It is best practice to only analyze your data in as big of segments as are absolutely necessary to obtain the desired statistics. If a large amount of data around a given event is pertinent to your study, it may become unmanageable to edit all at once. By checking Split into Segments, you can divide the specified timeline into smaller segments for more convenient analysis.

When this is selected, the grey lines on the timeline indicate the segments. Adjust the Segment Time to change the amount of time per segment.

It is possible to have partial segments if the total time is not evenly divisible by the segment time (as evident in the image above).

Multi-Event Mode

Multi-event mode allows you to specify a segment between two events. This is particularly useful if you use events to indicate the start and end of epochs in your study. The timeline is again present at the top, but event lines exist at either end. The names and times of each event are located next to the event line:

Use the left and right arrows to preview the segments which will be created from the selected events:

This is particularly useful when using Event Sources to define multi-event segments, since not all events being used will be obvious.

Events to Use

This section works very similarly to Event mode, except that each segment requires the selection of 2 events rather than one – a start event and an end event.

Again, there are 3 ways to select events – All, Event, or Event Source.

All

All events will be used for analysis. First event in file -> second event, second event -> third event, etc.

Event

When selecting by event, each segment is defined by two events.

Adding Events to Use

The start event will always be selected before the end event. To select the start event, drag and drop an event from the list. Notice how the column which contains the Start Event is highlighted green, ready to accept the event.

Once a start event has been selected, drag the second event into the list to set it as the end event.

Removing Events to Use

Events are removed from the list in pairs. Select the desired pair(s), drag out of the list:

And release the mouse button to remove from the list.

Event Source

Adding and removing event sources uses the same drag and drop principles as events, except items are selected from the Event Sources list:

Notice the list contains a # Pairs column. Since we are using event sources, and each of which could contain one or more event occurrences, there may be more than one possible segment between the start and end event sources. Let’s take the F11 event source as an example, which contains many event sources beneath it.

This is essentially saying “create segments from any subsequent occurrences of an F11 event”. In this file, there 7 events which fall under the F11 event source, so there will be a total of 6 segments created. This is where scrolling through event pairs becomes useful since the events themselves are not clearly listed in the Event Sources to Use list.

Split into Segments

Much like event mode, these multi-event segments can be further broken into smaller segments by checking Split into Multiple Segments

Again, segments are indicated by grey vertical lines on the timeline, and it is possible to have partial segments if the time between events is not evenly divisible by the Segment Time.

Startle Mode

Startle mode is unique to the EMG application and is designed to analyze EMG in a specific way to study the human startle response. This is typically done by measuring the response in facial muscles (particularly the eye blink) following some sort of visual or auditory stimulus. See this publication for more information on the recommended methodology.

Using the timeline

Startle response latency is measured in milliseconds after stimulus presentation. Since precise timing is so critical, Startle mode relies on events to define the segments of interest. Similar to Event mode, the black vertical line on the timeline indicates the event.

Notice that rather than specifying the time in seconds, milliseconds are used to define segment time in Startle Mode. Also, notice that there are a few different colors on the timeline. These colors correspond to the various time periods used during analysis and defined on this screen – the overall segment, the baseline period, and the analysis period.

Segment

The overall segment time is specified relative to the event using Start (ms) and End (ms) below the timeline. The segment is shaded green on the timeline unless that portion of time used for the baseline or analysis period (more on this in a moment).

Extending the segment before the baseline window/after the analysis window can be useful for examining activity during that time while not using it for response detection.

Baseline

The baseline period typically takes place pre-event, but must take place pre-analysis period. It is shaded orange in the timeline. The baseline period is specified using Start (ms) and End (ms) below the Baseline heading.

Analysis

The analysis period is the time in which a response is expected to happen post-event. In the timeline, this period is shaded blue and specified using Start (ms) and End (ms) below the Analysis heading.

Events to Use

This section works very similarly to Event mode, with one exception detailed in the Event Source selection mode. See the

Again, there are 3 ways to select events – AllEvent, and Event Source.

All

All events will be used for analysis. First event in file -> second event, second event -> third event, etc.

Event

Use event-based selection when there are specific instances of events that you want to analyze based on. Any of the events in the Events list can be selected for use. Ctrl-click to select multiple events, and Shift-click to select a range of events.

Adding Events to Use

To add events to this list, drag and drop events from the Events list into the Events to Use list. This is done by left-clicking on the desired events in the Events list and dragging those events out of that list and into the Events to Use list.

EMG Calibration Settings

Signal Processing

EMG data can be noisy, and often times requires additional processing to extract/isolate the significant components of the signal. The processing stages are applied in order (when enabled) from left to right:

Different filter settings are recommended for different signals/muscle groups.

Note: Automatically set and disabled when using edit files

Scaling

When analyzing data collected using MindWare hardware, the Incoming Units will always be volts. When analyzing other file types, be sure to specify the units stored in the file to properly convert to the selected Display Units. All amplitude-based statistics will be reported in these units.

Additionally, data collected in BioLab will automatically have amplifier gain divided out of the EMG signal. When using other file types where gain needs to be divided, or when the MindWare file does not contain the gain, it can be specified using the Amplifier Gain setting.

Calculation Method

Interval mode allows you to further break down each segment into smaller intervals. Only a few statistics are calculated for each interval:

  • RMS
  • Mean
  • Integral

RMS Calculation

Specify whether the root mean square (RMS) is calculated from the raw or processed EMG data

Channel Spacing

When viewing multiple EMG signals at the same time on a single graph, it can be useful to offset them to clearly see each of them. A specific offset can be specified, or the signals can be offset automatically based on the amplitude range of each signal.

Startle Response Processing

When analyzing data in Startle mode, the EMG Calibration Settings change slightly to reveal startle-specific options.

Baseline Correction

Used to remove any baseline offset present in the data. Enabling Baseline Correction will subtract the average amplitude of the unrectified baseline window from the processed EMG signal.

Response Onset Criteria

The onset of the response can be identified using a few different methods:

Standard Deviation –  Onset occurs when signal exceeds n standard deviations above baseline amplitude

Multiplier – Mark onset at point where signal exceeds a multiple of baseline amplitude

Slope – Onset is marked when a specified change in slope (in display units) is identified

Response Amplitude

Specify whether average baseline amplitude or onset amplitude is subtracted from the peak amplitude to determine response amplitude.

Response Threshold

Minimum value (in display units) for a significant response amplitude. Any response amplitudes below this threshold are flagged for further investigation.

BioLab Filter

In addition to the processing available on the EMG Calibration Settings tab, it is possible to apply the filter(s) used during acquisition in BioLab. To view/enable these filters, go to File>>BioLab Filters…

From this screen, you can view the filters which were used during acquisition, and apply them to each channel by pressing the Use BioLab Filters button

 

Note: This option will be disabled if no BioLab filters are available, or if you are using a data file type that wasn’t created by BioLab, or if you are using an edit file

Additional Settings

Like the Events and Modes section, these settings will be available in all MindWare analysis applications.

Video Settings

Up to 4 videos can be loaded for playback during data analysis. Viewing video can provide great insights into subject behavior and can be helpful in identifying the source of artifact in the data. Videos must be in either AVI or MPEG format. If your videos are in a different format, you can most likely find a converter online to translate them to one of these two formats.

Selecting videos for playback

When “Use Default Video Path” is selected, the application will automatically search for video files in the same directory as the data file which adhere to this naming convention:

Data-File-Name.mpg
Data-File-Name_camera 2.mpg

Videos collected in BioLab will automatically be named correctly and stored in the proper location. If you have moved/renamed your videos, or collected them using a different system, you will have to identify them manually. To do this, press the Browse button next to each video path and navigate to the desired video.

Using video delay

The start of video playback can be aligned to the start of the data file by setting a video delay

This is useful for when videos were collected with a separate application than the data file and the two applications were not started simultaneously. If the videos started before the data file, use a negative delay, and vice versa.

A note for Noldus Media Recorder users

If you are using Noldus Media Recorder in conjunction with BioLab to record your videos, you can restore the “default” video delay calculated at the time of acquisition by right-clicking the delay field and selecting Reset.

Enabling a video for playback

Make sure to press “Show Video” for each video you wish to view during analysis.

Output Settings

By default, the output file is stored in the subdirectory,

/Output Files/Current Date

of the same directory where the data file is stored.

If you would like to store your output files in a different directory by default, uncheck Use Default Directory? and modify the path as you see fit. You can always change the name and location of the output file when it is created during analysis as well.

Using Configuration Files

As mentioned in the first section, configuration files are a great way to backup your current settings or ensure that the application is configured exactly as you expect it to be.

Opening a Configuration File

To open a configuration file, go to Settings>>Open Configuration… and select a “.emgcfg2” configuration file.

Note: Opening a configuration file will override all current settings with those stored in the configuration file

Saving a Configuration File

To save a configuration file, go to Settings>>Save Configuration As…

Reinitialize All to Default

To start from scratch, go to Settings>>Reinitialize All to Default. This will clear all current settings, so be careful to not do this unless you intend to!

Proceeding to Analysis

To start data analysis, press the Analyze button:


 

Analysis Screen

The analysis screen is where data is viewed, transformed, and processed to produce statistics related to Electromyography. This screen will look different when analyzing data in Startle mode and is described in the next section.

Data Graphs

In this portion of the analysis screen, signals from the data file for the current segment are shown in various stages of processing. It is from these signals that all statistics are calculated.

Each graph has a set of graph tools, which can be used to zoom into and move through the data in finer detail. These tools are found in the lower left-hand corner of each graph. See this article for more information on how to use these tools.

EMG

The EMG graph shows one or more EMG signals in alternating colors. These colors correspond to the channel color in the Stats section of the screen.

When multiple channels are being viewed, these channels are spaced according to the setting on the EMG Calibration Settings page on the Setup screen. To switch to a single channel view, right-click on the EMG graph and select Show Single Channel…

In single channel view, the Channel Selector in the stats section specifies which channel is currently shown. The channel is shown in the Display Units specified on the Setup screen.

Event Markers

If events are being used for analysis, the locations of any events in the segment will appear as blue vertical lines throughout the segment. These event markers show up in both the EMG and Processed EMG plots.

To reveal the name and time of the event, hover the mouse over the vertical line:

Video Position

If videos have been selected for playback, a yellow vertical line indicating the current video position will appear:

Left-click and drag the yellow position line to update the video position accordingly:

Interval Mode

When analyzing in Interval mode, additional grey lines will appear on the graph indicating the intervals used for calculating each of the statistics.

Processed EMG

The processed EMG depicts the results of applying all enabled processing blocks from the EMG Calibration Settings screen during setup (Bandpass filter, rectification, etc.). Like the EMG graph, events are shown here and the color of the graph corresponds with the color assigned to the current channel being viewed.

EMG Power Spectrum

The processed EMG is then viewed from a frequency domain perspective to determine the peak frequency content in the waveform. Notice that the X axis is no longer in seconds, but in hertz.

Statistics

Channel Selection

Left click on the Channel Name in the statistics section and select a channel to view stats for it. This also updates the graphs to the left.

The following statistics are computed:

Peak Stats

From the Processed EMG graph, the peak amplitude and time (in seconds) are reported based on the maximum value detected in the segment. Additionally, the peak latency is determined as the time of the peak relative to the start of the segment (in seconds).

EMG Stats

The EMG Stats table contains 3 columns, one for each of 3 statistics:

  • RMS – Root mean square either calculated from the raw or processed EMG as specified on the setup screen
  • Mean – Average amplitude of processed EMG in display units
  • Integral – Area under the curve computed from the processed EMG

When analyzing in Entire mode, there will be a single row representative of the entire segment. If you are using Interval mode, each row will represent statistics for a single interval in the segment.

Power Spectrum Stats

From the EMG Power Spectrum, the peak frequency and the power at that frequency are reported.

Data Edits

The data edits display shows the amount of the signal (in time and percent of total signal) that has been estimated or removed using the signal editor. This will make more sense as you learn about the signal editor.

Use the left and right arrow buttons, or the left and right arrow keys on the keyboard to move forward/backward in the file.

To jump to a specific segment quickly, click the current segment number and select a new one from the list.

Advanced Segment Navigation

It is also possible to jump to the next (or previous) segment which meets certain criteria. These searches can take a few moments, so while they are taking place a small popup will appear. End the search at any time by pressing “Cancel”. The following options are available in the Search Menu

Next/Previous Unwritten Segment

Finds the next/previous segment which has not yet been written to the currently opened output file. This search can also be run by pressing Ctrl+Shift+Left Arrow or Ctrl+Shift+Right Arrow.

Writing data to the output file

Statistics and setup information can be written to an Excel spreadsheet (.xlsx) for import into study-level statistics applications, or for offline processing. Output files are automatically saved after each write.

Note: Excel does not need to be installed on the computer to successfully write output files

To write a segment, either press the white Write button, navigate to File>>Write Segment, or use the Ctrl+W hotkey.

When a segment has been written to the current output file, the Written light will be illuminated in the upper right-hand corner

If a segment has been edited since it was last written to the output file, the statistics in the output will no longer match what is on the analysis screen. To indicate this, the Written light will turn red

Be sure to re-write the segment in this case so that the output file contains the desired statistics.

Creating a new output file

To begin writing an output file, press the Write button on the toolbar. You will be prompted to select a location and filename for the output file:

The default name is:

Data file name_EMG Analysis_Current Time.xlsx

You are welcome to change this based on your needs. Once an output file is opened, you will see its filename appear in the title bar.

Opening an existing output file

To append a segment to an existing output file, either select an existing output file when prompted after pressing Write or go to File>>Open Output (or press Ctrl+O). Opening an output file will automatically detect which segments have already been written.

Note: This should only be done when analyzing the same data file using the same events & modes settings in the same analysis application. Appending to output files which were written with a different segmentation will have undesirable effects since the segment numbers overlap. 

When opening an existing output file, segments which have been written to that output file but could differ from the statistics currently shown on the analysis screen will cause Written light to turn yellow

If you believe your segments/edits have changed since the output file was last written, you should re-write the segment.

Saving and closing an output file

Output files are automatically saved after each segment write. They are also automatically closed when the Analysis screen is closed, but to close the output file manually go to File>>Save & Close Output.

Write All Segments

A shortcut to writing all segments to the output file can be found in File>>Write All Segments, or by pressing Ctrl+Shift+W on the keyboard. This mode will automatically iterate through all segments, writing each of them to Excel. This can take a few minutes depending on how many segments are being analyzed. You can press cancel on the popup at any time to end the process.

Note: this can be a time-saving tool and can give you an idea of what statistics have been calculated throughout the segments, but it is not a substitute for careful examination of data on a segment by segment basis. Be careful that this tool is not abused.

Data Editing

Often times data is not perfect – but that does not mean it isn’t salvageable with a bit of editing. To launch the signal editor, press the Signal Editor button in the toolbar.

If an edit file is currently being used, you will see the filename appear in the title bar. If the current segment has been edited, Edited will be illuminated in the upper right-hand corner.

Saving the edit file

A ‘*’ next to the edit file name means changes have been made but not yet saved to the file.

To save the changes to the edit file, go to File>>Save Edits or press Ctrl+S. If a new edit file is being created, a prompt will appear asking you to specify a name and location for the file. By default, edit files are saved in a subdirectory of the same directory as the data with the following naming convention:

/Edit Files/Data file name.edmg2

To save a copy of the currently opened edit file, go to File>>Save Edits As… or press Ctrl+Shift+S.

Video Playback

Video playback controls are found below the single video window. All standard video controls are here, including slow video playback. To jump to a specific time in the video (within the current segment), drag the time slider to the desired position. The yellow position in the ECG graph will update accordingly.

If more than one video has been selected for playback, multiple videos will be shown in a separate window.

Only one video will play its audio content at a time. This is indicated by a speaker symbol embedded in the video. To cycle through the audio on different videos, left-click the desired video.

Exiting the Analysis Screen

To close the analysis screen, press Done in the toolbar, go to File>>Exit, or simply close the window.

Startle Analysis

When analyzing in Startle mode, the analysis screen will look quite different from normal analysis:

Like the normal analysis screen, the Startle Analysis screen can be divided into sections.

Navigating through segments

Segments are organized in three levels – channels, conditions, and trials. Conditions correspond with Events specified on the setup screen, and Trials are occurrences of those events. As such, the current segment is defined as some combination of these. This is illustrated in the Current Segment selector as

Current Channel : Current Condition : Current Trial

For example, the segment “1:1:2” selected here means the segment depicts the first mapped channel, the first condition, and the second trial of that condition.

A special case exists for the average representation of a given condition (more on this later). When these segments are selected, the naming convention is as follows:

Current Channel : Current Condition : A

Use the left and right arrow buttons, or the left and right arrow keys on the keyboard to move forward/backward in the file. To jump to a specific segment quickly, click the current segment number and select a new one from the list.

Trials List

On the left side of the analysis window is a list of all channels, conditions, and trials (and condition averages) available for analysis. Left-click an item in the list to jump to that segment.

Advanced Segment Navigation

It is also possible to jump to the next (or previous) segment which meets certain criteria. These searches can take a few moments, so while they are taking place a small popup will appear. End the search at any time by pressing “Cancel”. The following options are available in the Search Menu:

Next/Previous Unwritten Condition

Statistics are written by the condition in Startle analysis. This option finds the next/previous condition which has not yet been written to the currently opened output file. This search can also be run by pressing Ctrl+Shift+Left Arrow or Ctrl+Shift+Right Arrow

Next/Previous Edited Trial

To quickly jump to the next/previous trial whose onset/peak has been moved, select this option or press Ctrl+Left Arrow or Ctrl+Right Arrow.

Next/Previous Unknown Trial

This can be useful for finding a trial whose state has not yet been specified (more on this below).

Data Graphs

This section of the analysis screen displays signals from the data file for the current segment in various stages of processing. The statistics on the right are calculated from these signals.

EMG

The EMG graph shows the currently selected channel before any signal processing in Display Units as specified on the Setup screen. Blue vertical lines indicate events (or conditions). Hover the mouse over them to display more information:

Video Position

If videos have been selected for playback, a yellow vertical line indicating the current video position will appear. Left-click and drag the yellow position line to update the video position accordingly:

Rectified EMG

The Rectified EMG graph shows the effect of the signal processing from the Band Pass, 50/60 Hz Filter, and Rectify processing steps. When Baseline Correction is enabled, the average amplitude in the baseline window from this signal is used.

Note: These steps produce a minimal phase shift in the signal, so viewing the data in this way can be useful for getting an idea of how much shift is present in the Startle Response below. 

Startle Response

The Startle Response graph shows the signal after all processing has been applied. There are a number of markings on this graph to indicate areas of interest and key points which have been identified.

The baseline and analysis windows which were specified on the setup screen are indicated by the vertical dashed orange and blue lines, respectively:

The detected response onset is identified by a green vertical line and point on the waveform. The peak following the onset is similarly identified, but with a white line and point:

The specified response threshold is marked by a horizontal dashed yellow line. If this line isn’t visible, it is likely that the response amplitude in the current segment is significantly below the threshold.

Trial State

When a file is first opened, all trials have an unknown state. This is illustrated by a grey circle next to the trial in the list.

On the right side of the screen, above the Stats table, are three buttons corresponding to the three possible states for each trial.

The state designated for each trial has a bearing on how some condition-based statistics are computed, so it is important to specify the proper state for each trial:

Accept – An accepted trial is free from noise contamination and has exceeded the specified response threshold

Zero – Also referred to as “no response”, these trials are free from noise but the response to the condition is either too small or non-existent

Reject – Trials should be rejected when noise has contaminated either the baseline or analysis windows in such a way that a valid response cannot be determined

When a trial state has been selected, only that state button will retain its color and the corresponding item in the Trials list will be updated accordingly:

Statistics

The following statistics are computed from the Startle Response waveform:

Baseline Stats

The average baseline amplitude is reported in the display units.

Response Stats

Response onset is identified using the Response Onset Criteria selected on the Setup screen. The amplitude of the onset as well as its latency (in milliseconds) from the event is reported.

The maximum value after the identified onset (but still within the analysis window) is identified as the peak. Again, the amplitude and latency are reported.

Finally, Response Amplitude is calculated according to the Response Amplitude setting on the Setup screen. When the response amplitude has not exceeded the Response Threshold, this statistic will turn red.

Condition Stats

Condition statistics take into account all trials of a given condition and are impacted by the states assigned to those trials.

Response Amplitude – Average response amplitude excluding trials marked as “Zero” or “Reject”

Response Magnitude – Response Amplitude * Probability

Probability – Ratio of trials marked as “Accept” or “Unknown”, excluding those marked as “Reject”

Average Stats

When viewing a segment identified as Average rather than a trial number, the statistics are derived on an average response which is constructed using all trials of a given condition.

The average waveform is built by averaging all trials which have not been marked as “Reject”. The Rectified EMG waveforms are averaged because the raw waveform can be both positive and negative, which would cause the trials to cancel one another out. For this reason, there is no average raw waveform when viewing these type of segments.

Note: It is possible to accept, zero, or reject the average segment, but this has no bearing on the Condition Stats. This is simply available for reporting purposes in the output file.

Writing data to the output file

Statistics and setup information can be written to an Excel spreadsheet (.xlsx) for import into study-level statistics applications, or for offline processing. Output files are automatically saved after each write.

Note: Excel does not need to be installed on the computer to successfully write output files

As touched on above, entire conditions are written at once in Startle analysis as opposed to individual segments. To write a condition, either press the white Write button, navigate to File>>Write Segment, or use the Ctrl+W hotkey.

When a segment has been written to the current output file, the Written light will be illuminated in the upper right-hand corner

If a segment has been edited since it was last written to the output file, the statistics in the output will no longer match what is on the analysis screen. To indicate this, the Written light will turn red

Be sure to re-write the segment in this case so that the output file contains the desired statistics.

Creating a new output file

To begin writing an output file, press the Write button on the toolbar. You will be prompted to select a location and filename for the output file:

The default name is:

Data file name_Startle EMG Analysis_Current Time.xlsx

You are welcome to change this based on your needs. Once an output file is opened, you will see its filename appear in the title bar.

Opening an existing output file

To append a segment to an existing output file, either select an existing output file when prompted after pressing Write or go to File>>Open Output (or press Ctrl+O). Opening an output file will automatically detect which conditions have already been written.

Note: This should only be done when analyzing the same data file using the same events & modes settings in the same analysis application. Appending to output files which were written with a different segmentation will have undesirable effects since the segment numbers overlap. 

When opening an existing output file, conditions which have been written to that output file but could differ from the statistics currently shown on the analysis screen will cause Written light to turn yellow

If you believe your conditions/edits have changed since the output file was last written, you should re-write the segment.

Saving and closing an output file

Output files are automatically saved after each condition write. They are also automatically closed when the Analysis screen is closed, but to close the output file manually go to File>>Save and Close Output.

Write All Conditions

A shortcut to writing all conditions to the output file can be found in File>>Write All Segments, or by pressing Ctrl+Shift+W on the keyboard. This mode will automatically iterate through all segments, writing each of them to Excel. This can take a few minutes depending on how many segments are being analyzed. You can press cancel on the popup at any time to end the process.

Note: this can be a time-saving tool and can give you an idea of what statistics have been calculated throughout the segments, but it is not a substitute for careful examination of data on a segment by segment basis. Be careful that this tool is not abused.

Data Editing

Unlike normal EMG analysis, there is no separate signal editor in Startle mode. It is possible, however, to manually adjust the onset and peak placement on the Startle Response graph by left clicking and dragging them to a new location.

When a trial is edited, it will appear in italics in the Trial List and Edited will be illuminated in the upper right-hand corner.

Saving the edit file

A ‘*’ next to the edit file name means changes have been made but not yet saved to the file.

To save the changes to the edit file, go to File>>Save Edits or press Ctrl+S. If a new edit file is being created, a prompt will appear asking you to specify a name and location for the file. By default, edit files are saved in a subdirectory of the same directory as the data with the following naming convention:

/Edit Files/Data file name.edmgh2

To save a copy of the currently opened edit file, go to File>>Save Edits As… or press Ctrl+Shift+S.

Video Playback

Video playback controls are found below the single video window. All standard video controls are here, including slow video playback. To jump to a specific time in the video (within the current segment), drag the time slider to the desired position. The yellow position in the ECG graph will update accordingly.

If more than one video has been selected for playback, multiple videos will be shown in a separate window.

Only one video will play its audio content at a time. This is indicated by a speaker symbol embedded in the video. To cycle through the audio on different videos, left-click the desired video.

Exiting the Analysis Screen

To close the analysis screen, press Done in the toolbar, go to File>>Exit, or simply close the window.

If any edits have been made but not saved, you will be prompted to save or discard those changes prior to closing the screen.

Signal Editor

No matter how hard you try, your data set will not be perfect. Electrodes, lead wires, physical movement, and much more can lead to impossible fluctuations in the EMG signal, or stronger EMG signals will infiltrate those signals which require more sensitive measurement. The signal editor is used to correct these mistakes.

Data Graph

The data graph is loaded with the same data used on the analysis screen for the current segment. Unlike the analysis screen, these signals are never spaced from one another. This is because it is important to have an idea of actual amplitude when making edits. There are some options for modifying which channels are edited and in what way using the Channels options in the toolbar.

Additionally, there are two vertical blue cursors and two horizontal green cursors on the graph. They are referred to as X cursors and Y cursors, respectively, after the axis upon which they move. These are used for several of the tools in the editor to define regions of interest. To move them, left-click and drag them to the desired location.

Editing requires a bit of precision with the mouse, and often times this is made much easier by zooming into sections of the data that require attention. The same graph tools from the analysis screen are available in the editor for various types of zooming. See this article for more information on how to use these tools.

Pressing the space bar will automatically cycle through the tools.

To scroll through the data once zoomed in, use the scroll bar at the top of the graph. You can also adjust the window size to precisely change the amount of data on the screen.

To scroll through the data second by second, press the left and right arrow keys on the keyboard.

Data Edits

Remember this information from the analysis screen? It is also found in the editor, where it is updated in real time as edits are made. This can be very useful for ensuring that you aren’t exceeding any editing limitations.

The View menu is used to toggle between the channel data edits shown here

Toolbar

Channels

This list contains all channels that are being edited, along with two characteristics – Mode and Color.

There are 3 modes for each channel – Edit, View, and Hide.

In Edit mode, various editing actions will affect the channel when they are performed. When a channel is in View mode, that channel is only shown in the graph for reference, and will not be affected by editing. Finally, Hide mode will remove the channel from the graph.

To change the color of the signal in the graph, left-click on the color column and select a new one from the window.

Data Editing

Data editing tools affect the signal itself. Each of these tools makes use of the X cursors for defining the affected area of the signal(s).

Remove

The Remove action sets a portion of the waveform to 0. To remove a portion of the signal, drag the X cursors to the appropriate locations and press Remove:

Spline

Splining is useful when signal amplitude must be maintained. Like above, adjust the X cursors to the area you want to estimate, and press Spline:

Extend

Extend allows you to preserve the signal amplitude while removing data from the beginning/end of the segment. << Extend uses the leftmost cursor position and extends that data value to the beginning of the segment.

Extend >> uses the rightmost cursor position and extends that data value to the end of the segment.

Cursors

We’ve been talking about cursors extensively throughout this section, and as they are moved the values in this section of the toolbar are updated. You can also specify exactly where a cursor is placed by modifying each position manually.

When Auto-Track is enabled, cursor locations will automatically be updated when scrolling/zooming into data. This is useful to ensure the cursor doesn’t end up out of view. When unchecked, cursors will retain their position regardless of scrolling/zooming.

Some Additional Functions

Saving the edit file

The edit file can be saved in the signal editor as you are performing edits. To do this, go to File>>Save or press Ctrl+S. To save a copy of the current edit file, go to File>>Save As… or press Ctrl+Shift+S.

Undo/Redo

Don’t like an edit you just made? Or the last three edits? Go to Edit>>Undo or press Ctrl+Z to revert back to before that edit. The description in the edit menu gives some insight into the action that will be reversed.

Changed your mind again? Go to Edit>>Redo or press Ctrl+Shift+Z to redo the previously undone action.

Undo/Redo All

Don’t like any of the edits you have performed in this editing session? Go to Edit>>Undo All to undo all changes made to the signals since the editor has been open. Or use Edit>>Redo All to re-apply anything you may have undone. This does not affect edits performed in prior editing sessions.

Returning to analysis

When you are finished editing, go to File>>Close or close the window to return to the analysis screen:

Conclusion

If you are eager to learn more, please visit our blog for deep dives into the scientific aspects of the applications, or our knowledge base for more technical information. 

Thank you for taking the time reading this manual, and we wish you the best of luck in your research endeavors!