FusedQDA: Quadratic Discriminant Analysis with Ridge Fused Inverse...

Description Usage Arguments Value Author(s) Examples

View source: R/RidgeFused.R

Description

Calculates the parameter estimates associated with quadratic discriminant analysis

Usage

1
FusedQDA(X,Lambda1,Lambda2,scaleC=FALSE)

Arguments

X

A list where each element contains the data of a different class

Lambda1

Ridge tuning parameter, must be greater than or equal to 0

Lambda2

Ridge Fusion tuning parameter, must be greater than or equal to 0

scaleC

If TRUE scale invariant method is used

Value

An object of class RidgeFusedQDA, basically a list including elements

Omega

a list where each element is the inverse covariance matrix estimate for the corresponding element of X

Means

A list of class means

Pi

Class Proportions

Lambda1
Lambda2
iter

Number of iterations until convergence

Author(s)

Brad Price

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
## Creating a toy example with 5 variables
library(mvtnorm)
set.seed(526)
p=5
    Sig1=matrix(0,p,p)
	for(j in 1:p){
		for(i in j:p){          
            Sig1[j,i]=.7^abs(i-j)
            Sig1[i,j]=Sig1[j,i]
            
		}
	}
Sig2=diag(c(rep(2,p-5),rep(1,5)),p,p)
X1=rmvnorm(100,rep(2*log(p)/p,p),Sig1)
Y=rmvnorm(100,,Sig2)
Z=list(X1,Y)
A2=FusedQDA(Z,10,10,scale=TRUE)
names(A2)

RidgeFusion documentation built on May 1, 2019, 8:03 p.m.