intercept_basis | R Documentation |
A simple intercept as basis function
intercept_basis(ui = c("none", "increasing", "decreasing"), negative = FALSE)
ui |
a character describing possible constraints |
negative |
a logical indicating negative basis functions |
intercept_basis
returns a function for the evaluation of
the basis functions with corresponding model.matrix
and predict
methods.
### set-up basis ib <- intercept_basis() ### generate data + coefficients x <- as.data.frame(mkgrid(ib)) ### 2 * 1 predict(ib, newdata = x, coef = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.