Learn R Programming

heartbeatr (version 1.0.0)

pulse_find_peaks_all_channels: Determine the heartbeat rate in all channels of a PULSE split window

Description

Take data from PULSE data window and run pulse_find_peaks_one_channel in all channels.

Usage

pulse_find_peaks_all_channels(split_window)

Value

A tibble with up to 10 rows (one for each channel) and 7 columns:

  • id, PULSE channel IDs

  • time, time at the center of split_window_one_channel$time

  • data, a list of tibbles with raw PULSE data for each combination of channel and window, with columns time, val and peak (TRUE when data points correspond to wave peaks)

  • hz, heartbeat rate estimate (in Hz)

  • n, number of wave peaks identified

  • sd, standard deviation of the intervals between wave peaks (normalized)

  • ci, confidence interval (hz ± ci)

Arguments

split_window

one element of the pulse_data_split list() (which is the output from pulse_split()).

BPM

To convert to Beats Per Minute, simply multiply hz and ci by 60.

See Also

  • pulse_find_peaks_all_channels() runs pulse_find_peaks_one_channel() on all PULSE channels

  • pulse_read(), pulse_split(), pulse_optimize(), pulse_heart() and pulse_choose_keep() are the functions needed for the complete PULSE processing workflow

  • PULSE() is a wrapper function that executes all the steps needed to process PULSE data at once

Examples

Run this code
## Begin prepare data ----
pulse_data_sub <- pulse_data
pulse_data_sub$data <- pulse_data_sub$data[,1:5]
pulse_data_split <- pulse_split(pulse_data_sub)
pulse_data_split <- pulse_optimize(pulse_data_split, multi = pulse_data$multi)
split_window <- pulse_data_split$data[[1]]
## End prepare data ----

# Determine heartbeat rates in all channels in one time window
pulse_find_peaks_all_channels(split_window)

Run the code above in your browser using DataLab