Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

shift

Shift values in a single-case data file


Description

Shifting the values might be helpful in cases where the measurement time is given as a time variable (see example below).

Usage

shift(data, value, var)

shiftSC(...)

Arguments

data

A single-case data frame. See scdf to learn about this format.

value

Number by which to shift the values

var

Character string with the name of the target variable. Defaults to the measurement time variable.

...

Further arguments passed to the function.

Value

A scdf with shifted data

See Also

Other data manipulation functions: fill_missing(), longSCDF(), outlier(), ranks(), smooth_cases(), standardize(), truncate_phase()

Examples

### Shift the measurement time for a better estimation of the intercept
ex <- shift(example_A24, value = -1996)
plm(ex)

scan

Single-Case Data Analyses for Single and Multiple Baseline Designs

v0.51
GPL
Authors
Juergen Wilbert [aut, cre], Timo Lueke [aut]
Initial release
2021-2-11

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.