Model Parameters
Parameter Term Structure Types
DiffFusion.ParameterTermstructure — Typeabstract type ParameterTermstructure <: Termstructure endAn abstract generic parameter term structure that provides methods to retrieve parameter values for various incarnations of signatures.
DiffFusion.PiecewiseFlatParameter — Typeabstract type PiecewiseFlatParameter <: ParameterTermstructure endA generic vector-valued model parameter term structure with piece-wise constant interpolation and constant extrapolation.
DiffFusion.BackwardFlatParameter — Typestruct BackwardFlatParameter <: PiecewiseFlatParameter
alias::String
times::AbstractVector
values::AbstractMatrix
endA generic vector-valued model parameter term structure with piece-wise constant backward-flat interpolation and constant extrapolation.
DiffFusion.backward_flat_parameter — Functionbackward_flat_parameter(
alias::String,
times::AbstractVector,
values::AbstractMatrix,
)Create a BackwardFlatParameter object for vector-valued parameters.
backward_flat_parameter(
alias::String,
times::AbstractVector,
values::AbstractVector,
)Create a BackwardFlatParameter object for scalar parameters.
DiffFusion.flat_parameter — Functionflat_parameter(value::ModelValue)Create a constant BackwardFlatParameter object.
flat_parameter(alias::String, value::ModelValue)Create a constant BackwardFlatParameter object.
flat_parameter(value::AbstractVector)Create a constant BackwardFlatParameter object.
flat_parameter(alias::String, value::AbstractVector)Create a constant BackwardFlatParameter object.
DiffFusion.ForwardFlatParameter — Typestruct ForwardFlatParameter <: PiecewiseFlatParameter
alias::String
times::AbstractVector
values::AbstractMatrix
endA generic vector-valued model parameter term structure with piece-wise constant forward-flat interpolation and constant extrapolation.
DiffFusion.forward_flat_parameter — Functionforward_flat_parameter(
alias::String,
times::AbstractVector,
values::AbstractMatrix,
)Create a ForwardFlatParameter object for vector-valued parameters.
forward_flat_parameter(
alias::String,
times::AbstractVector,
values::AbstractVector,
)Create a ForwardFlatParameter object for scalar parameters.
DiffFusion.time_idx — Methodtime_idx(ts::BackwardFlatParameter, t)Find the index such that T[idx-1] < t <= T[idx]. If t is larger than the last (or all) times T then return length(T)+1.
Functions
Call operator for ParameterTermstructure is defined as
(ts::ParameterTermstructure)(args...) = value(ts, args...)DiffFusion.value — Functionvalue(ts::ParameterTermstructure, result_size::TermstructureResultSize = TermstructureVector)Return a value for constant/time-homogeneous parameters.
value(ts::ParameterTermstructure, t::ModelTime, result_size::TermstructureResultSize = TermstructureVector)Return a value for a given observation time t.
value(ts::PiecewiseFlatParameter, result_size::TermstructureResultSize = TermstructureVector)Return a value for constant/time-homogeneous parameters.
value(ts::PiecewiseFlatParameter, t::ModelTime, result_size::TermstructureResultSize = TermstructureVector)Return a value for a given observation time t.
DiffFusion.time_idx — Methodtime_idx(ts::ForwardFlatParameter, t)Find the index such that T[idx] >= t > T[idx+1]. If t is smaller than the first (or all) times T then return 0.