next up previous contents
Next: B.4.5 newknn Up: B.4 Learners Previous: B.4.3 lr   Contents


B.4.4 lr_cgmle

This is an implementation of logistic regression (LR). LR computes $ \beta$ for which the model values $ \mu_i$ best approximate the dataset outputs $ y_i$ under the model

$\displaystyle \mu_i = \ensuremath{
\frac{ \ensuremath{\exp\left({{\beta}_0 + {\...
...eft({{\beta}_0 + {\beta}_1 {x_i}_1 +
\cdots {\beta}_{M} {x_i}_{M}}\right)} } }
$

where $ x_i$ is one dataset row. Please see [13,25,20,10] for details about logistic regression. This implementation uses a conjugate gradient algorithm [26,27,31,7] to maximize the LR log-likelihood

$\displaystyle \sum_{i=1}^R y_i \ln (u_i) + (1-y_i) \ln (1-u_i)
$

where $ R$ is the number of rows in the dataset. The current estimate of $ \beta$ is scored using the likelihood ratio $ -2 log( L_{\mbox{sat}} / L_{\mbox{current}})$, where $ L_{\mbox{sat})}$ is the likelihood of of a saturated model with $ R$ parameters and $ L_{\mbox{current}}$ is the likelihood of the current model. This ratio is called the ``deviance'', and the conjugate gradient iterations are terminated when the relative difference of the deviance between iterations is sufficiently small. Other termination measures can be added, such as a maximum number of iterations.




Keyword Arg Type Arg Vals Default
Common
cgeps float [1e-10, $ \infty$) 0.0005
rrlambda float [0.0, $ \infty$) 10.0
Rare
binitmean none    
cgdecay float [1.0, $ \infty$) 1000.0
cgmax int 0,...,$ \infty$ 100
cgwindow int 0,...,$ \infty$ 1
dufunc int 1,..., 4 1
initalpha float (0, $ \infty$) 1e-8
margin float [0, $ \infty$) 0.0
modelmax float (modelmin, 1.0] 1.0
modelmin float [0.0, modelmax) 0.0
     



Common keywords and arguments:

Rare keywords and arguments:


next up previous contents
Next: B.4.5 newknn Up: B.4 Learners Previous: B.4.3 lr   Contents
Copyright 2004 Paul Komarek, komarek@cmu.edu