Features#
Feature specifications turn raw columns into model terms. Spline is the
public factory for smooth terms; the concrete spline classes are what it
returns. Categorical, ordered-categorical, numeric, polynomial and piecewise
terms cover the rest of a rating structure; FactorSmooth and
RandomEffect add credibility-style shrinkage; Constraint requests
monotone or curvature constraints. The interaction types the constructor
builds from a pair of columns are on the Internals page.
Create a spline feature spec. |
|
P-spline: B-spline basis with a discrete-difference penalty. |
|
B-spline smooth: B-spline basis with an integrated-derivative penalty. |
|
Natural P-spline: f''=0 at boundaries, linear tails. |
|
CR spline: integrated f'' squared penalty + natural boundary constraints. |
|
Pin a spline to a polynomial of |
|
Convert basis dimension |
|
One-hot encoded categorical feature. |
|
Ordered categorical feature smoothed by a spline over its level values. |
|
A single continuous feature used as-is. |
|
Continuous piecewise-linear feature on stated breakpoints. |
|
Orthogonal polynomial feature (orthonormal in the training-weight measure). |
|
A factor-by-P-spline interaction. |
|
All-level categorical effect with a REML-estimated variance component. |
|
Mapping between original categorical levels and grouped levels. |
|
Build a |
|
The shape constraints a feature can carry, reached through |