Interactive demo · Statistical Methods for Modern Biology · Chapter 12

Ridge, lasso and elastic net: penalised logistic regression

A penalty on the size of the coefficients trades a little bias for a large drop in variance. The lasso penalty |β| sets small coefficients exactly to zero (soft-thresholding); the ridge penalty β² shrinks all of them in proportion; the elastic net mixes the two. Here they are used to predict colorectal cancer from 260 species abundances in stool samples (Zeller et al. 2014), with λ chosen by ten-fold cross-validation.

View

Mixing α (1 = lasso, glmnet convention)

Penalty λ

Features

Position on the path (index of λ)

Probability threshold for calling cancer

Scoreboard

Try these

In the lecture notes