transform | R Documentation |
Transformation of the X-data by a fitted model.
transform(object, X, ...)
object |
A fitted model, output of a call to a fitting function. |
X |
New X-data to consider. |
... |
Optional arguments. |
See the examples.
n <- 6 ; p <- 4
X <- matrix(rnorm(n * p), ncol = p)
y <- rnorm(n)
fm <- pcaeigen(X, nlv = 3)
#fm <- plskern(X, y, nlv = 3)
fm$T
transform(fm, X[1:2, ], nlv = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.