generate_imputation_input_windows: Internal utility for maximizing imputation data range

Description Usage Arguments Value

View source: R/fct_gp_impute_core.R

Description

generate_imputation_input_windows is designed to take in the time vector for the entire PPG series, and return a list containing the boundaries that define input data that will be used in the imputation model. The total amount of input data is defined by the expansion_factor, which is the number of total respiration cycles. The value in ibiVizEdit defaults to 3, and in the case of imputation models. Combined with the average respiration rate extracted from the PPG and IBI series, the total_input_time parameter represents the ideal of being able to use approximately three breaths worth of data before the window targeted for imputation and three breaths worth of data after the target window. When the target window approaches the beginning or end of a file, this function will distribute the total time around the target window as evenly as possible. The goal is to come as close as possible to the total amount of input data covering the amount of time defined by total_input_time.

Usage

1
2
3
4
5
6
generate_imputation_input_windows(
  time_vector,
  total_input_time,
  target_time_min,
  target_time_max
)

Arguments

time_vector

is a numeric vector that measures the passage of time for the entire PPG signal

total_input_time

is a numeric 1D vector based on the average number of seconds between breaths (derived) from a statistical analysis of the PPG and IBI signals, adjusting for user-defined age (see estimate_average_respiration()). This respiration interval length is then multiplied by an "expansion" factor. The default value for this expansion factor in ibiVizEdit is 3.

target_time_min

is a numeric 1D vector that contains the minimum time value of the user-defined imputation window.

target_time_max

is a numeric 1D vector that contains the maximum time value of the user-defined imputation window.

Value

list that contains the input imputation windows boundaries


dr-consulting/ibi_VizEdit documentation built on Jan. 1, 2021, 12:04 a.m.