Description Usage Arguments Value Examples
View source: R/FeatureSpaceProjection.R
applies FSP.image_ef
to every single 'image_ef' object of the 'imageset_ef' object.
The projected faces and the coefficients are returned as a list each (combined to another list)
1 2 | ## S3 method for class 'imageset_ef'
FSP(obj, eigenfaces, avgFace, showCoefficients = FALSE, ...)
|
obj |
an object of class 'imageset_ef' |
eigenfaces |
an object of class 'imageset_ef', eigenfaces of an 'imageset_ef' object td |
avgFace |
an object of class 'image_ef', average face of td |
showCoefficients |
(optional) logical vector of length 1 (TRUE or FALSE) |
... |
additional arguments |
case showCoefficients=FALSE
: a list of length 1 containing a list of objects of class 'image_ef',
projections of the elements of td
onto the linear span of eigenfaces
case showCoefficients=TRUE
: a list of length 2 additionally containing a list of numeric vectors where the
coefficients for the representation with the eigenfaces are saved.
1 2 3 4 5 6 | # Import Olivetti-faces
olivetti <- system.file("extdata","olivetti_X.csv",package="eigenfaces")
td <- load_imageset_ef(olivetti, c(64,64))
eigenfaces <- get_eigenfaces(td, nfaces = 50, quick=TRUE)
avgFace <- avg_face(td)
projection <- FSP(td, eigenfaces, avgFace, showCoefficients=FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.