plm: Piecewise linear model / piecewise regression
Description
The plm function computes a piecewise regression model (see Huitema & McKean, 2000).
Usage
plm(data, AR = NULL, model = "B&L-B", count.data = FALSE,
family = ifelse(count.data, "poisson", "gaussian"), ...)
Arguments
data
A single-case data frame or a list of single-case data frames. See makeSCDF to learn about this format.
AR
Maximal lag of autoregression. Modeled based on the Autoregressive-Moving Average (ARMA) function.
model
Regression model used for computation (see Huitema & McKean, 2000). Default is model = "B&L-B". Possible values are: "B&L-B", "H-M", "Mohr#1", "Mohr#2", and "Manly".
count.data
Still under development. Do not use.
family
Still under development. Do not use.
...
Further arguments passed to the glm function.
Value
model
Character string from function call (see Arguments above).
F
F value for specified model.
df1
Degrees of freedom (Regression).
df2
Degrees of freedom (Residual).
p
P value for specified model.
R2
Explained variance R squared.
R2.adj
Adjusted R squared.
count.data
Logical argument from function call (see Arguments above).
ES.slope
Effect size / Explained variance gain of slope.
ES.trend
Effect size / Explained variance gain of trend.
full.model
Full regression model list (including coefficients, residuals and many others
MT
Number of measurements.
data
Single-case data frame passed to the function.
N
Number of single-cases.
family
Character string from function call (see Arguments above).
References
Beretvas, S., & Chung, H. (2008). An evaluation of modified R2-change effect size indices for single-subject experimental designs. Evidence-Based Communication Assessment and Intervention, 2, 120-128.
Huitema, B. E., & McKean, J. W. (2000). Design specification issues in time-series intervention models. Educational and Psychological Measurement, 60, 38-58.
# NOT RUN {## Compute a piecewise regression model for a random single-casedat <- rSC(1, MT = 30, B.start = 11, d.level = 1.0, d.slope = 0.05, d.trend = 0.05)
plm(dat, AR = 3)
# }