Calls `flexsurv::flexsurvspline()`

.

lp is predicted by using an internally defined `predict`

method, see details

distr is predicted by using an internally defined `predict`

method, see details

`crank`

is identical to `lp`

Parameter `k`

is changed to `1`

and `scale`

is changed to `odds`

, as these are more in line with
the Royston/Parmar proposed models, and the package defaults are equivalent to fitting a
parametric model and therefore surv.parametric should be used instead.

If fitting a model with `k = 0`

then consider using surv.parametric as
this is likely to have more optimal results, and has more options for tuning.

## Details

The `distr`

prediction is estimated using the fitted custom distributions
from `flexsurv::flexsurvspline()`

and the estimated coefficients.

As flexible spline models estimate the baseline hazard as the intercept, the linear predictor,
`lp`

, can be calculated as in the classical setting. i.e. For fitted coefficients,
\(\beta = (\beta_0,...,\beta_P)\),
and covariates \(X^T = (X_0,...,X_P)^T\), where \(X_0\) is a column
of \(1\)s: \(lp = \beta X\).

## Dictionary

This Learner can be instantiated via the dictionary
mlr_learners or with the associated sugar function lrn():

LearnerSurvFlexible$new()
mlr_learners$get("surv.flexible")
lrn("surv.flexible")

Type: "surv"

Predict Types: `distr, lp, crank`

Feature Types: `logical, integer, factor, numeric`

Properties: `weights`

Packages: flexsurv survival distr6 set6

## References

Royston P, Parmar MKB (2002).
“Flexible parametric proportional-hazards and proportional-odds models for censored survival data, with application to prognostic modelling and estimation of treatment effects.”
*Statistics in Medicine*, **21**(15), 2175--2197.
doi: 10.1002/sim.1203
.

## See also

Dictionary of Learners: mlr3::mlr_learners

Other survival learners:
`LearnerSurvBlackboost`

,
`LearnerSurvCVGlmnet`

,
`LearnerSurvCoxPH`

,
`LearnerSurvGBM`

,
`LearnerSurvGamboost`

,
`LearnerSurvGlmboost`

,
`LearnerSurvGlmnet`

,
`LearnerSurvKaplan`

,
`LearnerSurvMboost`

,
`LearnerSurvNelson`

,
`LearnerSurvObliqueRSF`

,
`LearnerSurvParametric`

,
`LearnerSurvPenalized`

,
`LearnerSurvRandomForestSRC`

,
`LearnerSurvRanger`

,
`LearnerSurvRpart`

,
`LearnerSurvSVM`

## Super classes

`mlr3::Learner`

-> `mlr3proba::LearnerSurv`

-> `LearnerSurvFlexible`

## Methods

### Public methods

## Inherited methods

### Method `new()`

Creates a new instance of this R6 class.

### Usage

LearnerSurvFlexible$new()

### Method `clone()`

The objects of this class are cloneable with this method.

### Usage

LearnerSurvFlexible$clone(deep = FALSE)

### Arguments

`deep`

Whether to make a deep clone.