predict.princomp
Principal Component Scores

### Description

Returns a matrix of the scores for the principal components.

### Usage

    predict.princomp(object, newdata, ... )

### Arguments

object | object of class "princomp".
newdata | matrix or data frame of numeric data. The column names must include the variables used to compute object.

### Details

This is the "princomp" method for the generic function predict.
Value
matrix of principal component scores.
See Also
princomp, predict.
Examples

    wafer.pc <- princomp(~ pre.mean + post.mean + pre.dev + post.dev,
        data=Sdatasets::wafer)
    hyp.data <- data.frame(pre.mean=c(2,3), post.mean=c(2,3),
        post.dev=c(.2,.3), pre.dev=c(.1,.2))
    predict(wafer.pc, hyp.data)

Package stats version 6.1.5-18
Package Index