SPLS.binomial.GLM: Sparse Partial Least Squares-Generalized Linear Model...

Description Usage Arguments Value Author(s) Examples

View source: R/AllFunctions.R

Description

Takes in a set of predictor variables and a set of response variables and gives the SPLS-GLM parameters.

Usage

1
SPLS.binomial.GLM(X, y, A, lambdaY, lambdaX, eps = 0.001, ...)

Arguments

X

A (NxP) predictor matrix

y

A (Nx1) Binomial-distributed response vector

A

The number of PLS components

lambdaY

A value for the penalty parameters for the soft-thresholding penalization function for Y-weights

lambdaX

A value for the penalty parameters for the soft-thresholding penalization function for X-weights

eps

Cut off value for convergence step

...

Other arguments. Currently ignored

Value

The SPLS-GLM parameters of D=[X y]

Author(s)

Opeoluwa F. Oyedele and Sugnet Gardner-Lubbe

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
if(require(MASS))
data(Pima.tr, package="MASS")
X = as.matrix(cbind(Pima.tr[,1:7]))
dimnames(X) = list(1:nrow(X), colnames(X))
y = as.matrix(as.numeric(Pima.tr$type)-1, ncol=1)
#0=No and 1=Yes
dimnames(y) = list(1:nrow(y), paste("type"))
SPLS.binomial.GLM(scale(X), scale(y), A=2, lambdaY=0, lambdaX=0.96, eps=1e-3)
#lambdaX and lambdaY value are determined using function opt.penalty.values
#for more details, see opt.penalty.values help file

PLSbiplot1 documentation built on May 2, 2019, 9:41 a.m.