auc.dca: AUC optimization with DCA

Description Usage Arguments Details Examples

View source: R/dc_auc.R

Description

optimizes SAUC using a smoothed DCA algorithm.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
dcsauc (formula, data, ...)
srauc (formula, data, ...)
auc.dca (formula, data, 
    type="srauc",
    kernel="linear", para=NULL,  
    lambda=.1, zeta=.1, b=10, s=1, epsilon=1e-3, 
    method="tron", decomposition=TRUE,
    dca.control =  list(maxit=1e3, abstol=1e-5, coef.init=NULL, lincomb.init=NULL),
    tron.control = list(q=50, maxfev=1e3, gtol=1e-2, frtol=1e-12, K.thresh=1, verbose=0),
    return.K=FALSE, verbose = FALSE
)

Arguments

formula

formula, e.g. y~x1+x2

data

a data frame

type

string. Either srauc or dcsauc

kernel

See getK for more details

para

See getK for more details

lambda

scale parameter of the penalty function, defaults to 1

zeta

parameter (->0+) in writing sigmoid function as differene of two convex functions.

b

'decay rate' parameter in sigmoid function 1/(exp(bx))

s

the parameter in rauc

epsilon

the parameter in the approximation of a hinge function

method

the optimizer to use, "tron", or an optim method

decomposition

Boolean. If TRUE, decomposition strategy is used if tron is the method

dca.control

list of control parameters for the DCA algorithm

tron.control

list of control parameters to 'tron' optimizer

return.K

logical, whether to return the Kernel matrix

verbose

logical, whether to print info as alg. progresses

...

parameters passed to auc.dca

Details

dcsauc and srauc pass directly to auc.dca with the name-sake type.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
#
#
#dat = sim.dat.1(n=100,seed=1)
#dat.test = sim.dat.1(n=1e3,seed=1000)
#
#t.1 = system.time({
#    fit.1=sauc.dca(y~x1+x2, dat, zeta=.1)
#})
#
#t.2 = system.time({
#    fit.2=sauc.dca(y~x1+x2, dat, zeta=1)
#})
#
## compare time
#rbind(t.1, t.2)[,3]
#
## compare performance
#RUnit::checkEqualsNumeric(
#    c(fit.1$train.auc, fit.2$train.auc)
#, c(0.7291917, 0.7282913), tolerance=1e-6)
#

aucm documentation built on Jan. 11, 2020, 9:43 a.m.

Related to auc.dca in aucm...