meridian.model.knots.get_knot_info

Returns the number of knots, knot locations, and weights.

n_times
The number of time periods in the data.
knots
An optional integer or a collection of integers indicating the knots used to estimate time effects. When knots is a collection of integers, the knot locations are provided by that collection. Zero corresponds to a knot at the first time period, one corresponds to a knot at the second time, ..., and (n_times - 1) corresponds to a knot at the last time period. When knots is an integer, then there are knots with locations equally spaced across the time periods (including knots at zero and (n_times - 1) . When knots is 1 , there is a single common regression coefficient used for all time periods. If knots is None , then the numbers of knots used is equal to the number of time periods. This is equivalent to each time period having its own regression coefficient.
enable_aks
A boolean indicating whether to use the Automatic Knot Selection algorithm to select optimal number of knots for running the model instead of the default 1 for national and n_times for non-national models.
data
An Optional InputData object used by the Automatic Knot Selection algorithm to calculate optimal number of knots from the provided Input Data.
is_national
A boolean indicator whether to adapt the knot information for a national model.

A KnotInfo that contains the number of knots, the location of knots, and the weights used to multiply with the knot values to get time-varying coefficients.

Design a Mobile Site
View Site in Mobile | Classic
Share by: