Professional Documents
Culture Documents
ISCB 2015
In practice:
Most often a linear relationship of x with g(y ) is assumed
Still people tend to categorise covariates. See Greenland 1995,
Royston, Altman & Sauerbrei 2006 for reasons against it.
Sometimes a simple transformation might be considered, such as
log(x ), x 2 ...
Fractional Polynomials Royston & Altman 1994
Splines
y = —0 + —1 x + ‘
x ≠min(x )
where u = max(x )≠min(x )
1.0
0.5
0.5
0.0
0.0
−0.5
−0.5
−1.0
−1.0
0 20 40 60 80 0 20 40 60 80
1.0
0.8
0.8
0.6
0.6
0.4
0.4
0.2
0.2
0.0
0.0
0 20 40 60 80 0 20 40 60 80
1.0
0.8
0.8
0.6
0.6
0.4
0.4
0.2
0.2
0.0
0.0
0 20 40 60 80 0 20 40 60 80
−2
Poly.
−4
Trunc. Poly.
B−Splines (R)
B−Splines
Natural
Gaussian
−6
4
2
2
0
0
y
y
−2
−2
−4
−4
−6
−6
0.0 0.2 0.4 0.6 0.8 1.0 0.0 0.2 0.4 0.6 0.8 1.0
x x
12 Knots 24 Knots
4
4
2
2
0
0
y
y
−2
−2
−4
−4
−6
−6
0.0 0.2 0.4 0.6 0.8 1.0 0.0 0.2 0.4 0.6 0.8 1.0
x x
Degree 1 Degree 2
4
4
2
2
0
0
y
y
−2
−2
−4
−4
−6
−6
0.0 0.2 0.4 0.6 0.8 1.0 0.0 0.2 0.4 0.6 0.8 1.0
x x
4
2
2
0
0
y
y
−2
−2
−4
−4
−6
−6
0.0 0.2 0.4 0.6 0.8 1.0 0.0 0.2 0.4 0.6 0.8 1.0
x x
http://drperpo.github.io/docs/rpackages/splines.html
Bayesian: 1
Boosting: 2
Classification: 1
Functions: 4
Regression: 14
Splines: 1
package p- splines RE
mgcv x x
quantreg x x
survival x x
VGAM x x
gbm x
gam x
gamlss x x