Learn R Programming

metaX (version 1.4.0)

calcVIP: Calculate the VIP for PLS-DA

Description

Calculate the VIP for PLS-DA

Usage

calcVIP(x, ncomp, ...)

Arguments

x
An object of output from plsr
ncomp
The number of component used in PLS-DA
...
Additional parameters

Value

An vector of VIP value

Examples

Run this code
library(pls)
x <- matrix(rnorm(1000),nrow = 10,ncol = 100)
y <- rep(0:1,5)
res <- plsr(y~x)
calcVIP(res,2)

Run the code above in your browser using DataLab