dat2poly | R Documentation |
This is a convenience function that will take each column of the input and calculate 1:degree powers and concatenate
into a data.frame of dimensions n * (degree * p)
given an n * p
input
dat2poly(
dat,
method = c("simple", "poly"),
degree = 2,
raw = FALSE,
as.data.frame = TRUE
)
dat |
Numeric, matrix / data.frame: Input |
method |
Character: "simple", "poly". "simple": raise each column of |
degree |
Integer: degree of polynomials to create. Default = 2 |
raw |
Logical: If TRUE, create simple polynomial, not orthogonalized. Default = FALSE |
as.data.frame |
Logical: If TRUE, return data.frame. Default = TRUE |
E.D. Gennatas
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.