split_vec: Segment data

View source: R/frequency_analysis.R

split_vecR Documentation

Segment data

Description

Split data into segments for Welch PSD. Any leftover data is discarded (i.e. if seg_length is 256 and signal length is 400, only 1 segment is returned)

Usage

split_vec(vec, seg_length, overlap, detrend = "mean")

Arguments

vec

Data vector to be split up into segments.

seg_length

Length of segments to be FFT'd (in samples).

overlap

Overlap between segments (in samples).

detrend

Detrend segments. Defaults to "mean" - removes mean from each segment. Anything else turns off detrending.

Author(s)

Matt Craddock matt@mattcraddock.com


neuroconductor/eegUtils documentation built on Feb. 3, 2023, 5:33 p.m.