step_fft_transfer_experimental: step_fft_transfer_experimental

View source: R/api_recipes.R

step_fft_transfer_experimentalR Documentation

step_fft_transfer_experimental

Description

Calculates the transfer function with pgram results.

Usage

step_fft_transfer_experimental(
  .rec,
  terms,
  spans = 3,
  detrend = TRUE,
  demean = TRUE,
  taper = 0.1,
  n_groups = 200,
  time_step = 1,
  formula = NULL,
  role = "augment",
  ...
)

Arguments

.rec

the R6 recipe object.

terms

the unquoted names of the variables to use or a selector function. terms replaces the '...' of the recipes package but requires variables to be included within 'c()'. For example to include variables x and y you would write 'c(x,y)' in the hydrorecipes package.

spans

vector of odd integers giving the widths of modified Daniell smoothers to be used to smooth the periodogram.

detrend

logical. If TRUE, remove a linear trend from the series. This will also remove the mean.

demean

logical. If TRUE, subtract the mean of the series.

taper

specifies the proportion of data to taper. A split cosine bell taper is applied to this proportion of the data at the beginning and end of the series.

n_groups

number of results

role

character - the name of the role

...

additional arguments

power

spacing for the groups

Value

an updated recipe

Examples

data(kennel_2020)

form <- as.formula("wl~.")

rec <- recipe(form, kennel_2020) |>
       step_fft_transfer_experimental(c(wl, baro, et), spans = 3) |>
       plate()


jkennel/hydrorecipes documentation built on Dec. 24, 2024, 5:38 p.m.