Description Usage Arguments Value Examples
Returns the regression coefficients from a TANDEM fit.
1 2 |
object |
A tandem-object, as returned by tandem() |
... |
Not used. Other arguments for coef(). |
The regression coefficients.
1 2 3 4 5 6 7 8 9 | # unpack example data
x = example_data$x
y = example_data$y
upstream = example_data$upstream
# fit a tandem model, determine the coefficients and create a prediction
fit = tandem(x, y, upstream, alpha=0.5)
beta = coef(fit)
y_hat = predict(fit, newx=x)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.