Skip to content

Functions for reading e4 data, and create several parameters for analysis

Notifications You must be signed in to change notification settings

PCdLf/wearables

Repository files navigation

Overview

wearables

Functions for analyzing empatica e4 data, pre-process the signals, detect artifacts and create several features for analysis.

We are working on functionality to also process Empatica EmbracePlus and Nowatch data. These devices can be found here:

https://www.empatica.com/embraceplus/ https://nowatch.com/

Current functionality includes the read_embrace_plus function, that can be used to read in the zip file coming from the Empatica EmbracePlus device. This zip file contains .avro files.

This package was originally created for signal analysis of the Empatica E4 wearables device. It allows users to read in an E4 zip file from Empatica connect into a list. The package was created to detect artifacts and extract features that can be used for analysis.

  • 'read_e4()' is the first function that can be used to read Empatica E4 data into a list.
  • 'read_and_process()' is a function to perform analyses on the heart rate, electrodermal activity, accelerometry and temperature data.

If you are new to Empatica E4, the best place to start is the website from Empatica or the accompanying website for the Shiny tool .

R-CMD-check

Installation

This package is available on CRAN:

#install the wearables package:
install.packages("wearables")

Or get the development version from GitHub:

install.packages("remotes")
remotes::install_github("PCdLf/wearables")

Getting started

Below are some instructions to get started with wearables, using example data from the E4.

You can get a small example dataset for the E4 by using data(e4):

library(wearables)

# result would be equivalent to 
#e4_data <- read_e4("Your filepath to zip-file here")

data(e4_data)

Subsequently, you can process this data:

processed_e4_data <- process_e4(e4_data)

#read_e4("Your filepath to zip-file here") #read_and_process_e4("Your filepath to zip-file here")

This will do the following:

  • Analyzing IBI data
  • Filtering EDA data
  • Peak detection
  • Compute EDA Features
  • Generate model predictions and classify artifacts

With this processed data, you can also plot the artifacts, using eda_bin and eda_peaks from the resulting object:

plot_artifacts(processed_e4_data$eda_bin, processed_e4_data$eda_peaks)

Screenshot of the resulting plot using the plot_artifacts() function

Getting help

If you encounter a clear bug, please file an issue with a minimal reproducible example on GitHub.

About

Functions for reading e4 data, and create several parameters for analysis

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages