TimeVaryingResult¶
- class TimeVaryingResult(*args)¶
Distribution factory result for non stationary likelihood estimation.
We consider a non stationary GEV model to describe the distribution of :
We have the values of on the time stamps .
For numerical reasons, the time stamps have been normalized using the linear function:
Each of has an expression in terms of a parameter vector and time functions:
where:
is usually referred to as the inverse-link function. The function denotes either , or ,
each is a scalar function ,
each .
We denote by , and the size of the functional basis of , and respectively. We denote by the complete vector of parameters.
The estimator of vector maximizes the likelihood of the Parent distribution.
- Parameters:
- factory
DistributionFactory
Parent distribution factory.
- data2-d sequence of float
Data.
- parameterFunction
Function
The function .
- timeStamps2-d sequence of float
Values of .
- parameterDistribution
Distribution
The distribution of .
- normalizationFunction
LinearFunction
The normalization function .
- llhfloat
Maximum log-likelihood.
- factory
See also
Methods
Draw the 4 usual diagnostic plots.
drawParameterFunction
([parameterIndex])Draw the parameter function.
Draw the quantile function.
Accessor to the object's name.
Accessor to the Parent distribution at a given time.
getId
()Accessor to the object's id.
Optimal log-likelihood value accessor.
getName
()Accessor to the object's name.
Normalizing function accessor.
Optimal parameter accessor.
Accessor to the distribution of .
Parameter function accessor.
Accessor to the object's shadowed id.
Accessor to the time grid.
Accessor to the object's visibility state.
hasName
()Test if the object is named.
Test if the object has a distinguishable name.
setLogLikelihood
(logLikelihood)Optimal log-likelihood value accessor.
setName
(name)Accessor to the object's name.
setParameterDistribution
(parameterDistribution)Accessor to the distribution of of .
setShadowedId
(id)Accessor to the object's shadowed id.
setVisibility
(visible)Accessor to the object's visibility state.
- __init__(*args)¶
- drawDiagnosticPlot()¶
Draw the 4 usual diagnostic plots.
If is a non stationary GEV model defined as follows:
then the standardized variables defined by:
have the standard Gumbel distribution which is the GEV model with .
Then, the 4 diagnostic graphs are built from the transformed data compared to the Gumbel model: the probability-probability plot, the quantile-quantile plot, the return level plot, the data histogram with the Gumbel distribution.
If denotes the ordered block maximum transformed data, the graphs are defined as follows.
The probability-probability plot consists of the points:
The quantile-quantile plot consists of the points:
The return level plot consists of the points:
and the points:
where is the empirical -block return level of the transformed data and the -block return level of the Gumbel distribution.
- Returns:
- grid
GridLayout
- Returns a grid of 4 graphs:
the QQ-plot,
the PP-plot,
the return level graph (with confidence lines),
the density graph.
- grid
- drawParameterFunction(parameterIndex=0)¶
Draw the parameter function.
- Parameters:
- parameterIndexint,
The index specifying the marginal of .
- Returns:
- graph
Graph
Graph of .
- graph
- drawQuantileFunction(p)¶
Draw the quantile function.
The quantile function is the function where is the quantile of order of the Parent distribution at time .
- Parameters:
- pfloat
The quantile level.
- Returns:
- graph
Graph
Quantile function graph.
- graph
- getClassName()¶
Accessor to the object’s name.
- Returns:
- class_namestr
The object class name (object.__class__.__name__).
- getDistribution(t)¶
Accessor to the Parent distribution at a given time.
- Parameters:
- tfloat
Time value.
- Returns:
- distribution
Distribution
The Parent distribution at time .
- distribution
- getId()¶
Accessor to the object’s id.
- Returns:
- idint
Internal unique identifier.
- getLogLikelihood()¶
Optimal log-likelihood value accessor.
- Returns:
- llhfloat
Maximum log-likelihood.
- getName()¶
Accessor to the object’s name.
- Returns:
- namestr
The name of the object.
- getNormalizationFunction()¶
Normalizing function accessor.
- Returns:
- normalizeFunction
Function
The function .
- normalizeFunction
- getOptimalParameter()¶
Optimal parameter accessor.
- Returns:
- optimalParameter
Point
Optimal vector of parameters .
- optimalParameter
- getParameterDistribution()¶
Accessor to the distribution of .
- Returns:
- parameterDistribution
Distribution
The distribution of the estimator of .
- parameterDistribution
- getParameterFunction()¶
Parameter function accessor.
- Returns:
- parameterFunction
Function
The function .
- parameterFunction
- getShadowedId()¶
Accessor to the object’s shadowed id.
- Returns:
- idint
Internal unique identifier.
- getVisibility()¶
Accessor to the object’s visibility state.
- Returns:
- visiblebool
Visibility flag.
- hasName()¶
Test if the object is named.
- Returns:
- hasNamebool
True if the name is not empty.
- hasVisibleName()¶
Test if the object has a distinguishable name.
- Returns:
- hasVisibleNamebool
True if the name is not empty and not the default one.
- setLogLikelihood(logLikelihood)¶
Optimal log-likelihood value accessor.
- Parameters:
- llhfloat
Maximum log-likelihood.
- setName(name)¶
Accessor to the object’s name.
- Parameters:
- namestr
The name of the object.
- setParameterDistribution(parameterDistribution)¶
Accessor to the distribution of of .
- Parameters:
- parameterDistribution
Distribution
The distribution of the estimator of .
- parameterDistribution
- setShadowedId(id)¶
Accessor to the object’s shadowed id.
- Parameters:
- idint
Internal unique identifier.
- setVisibility(visible)¶
Accessor to the object’s visibility state.
- Parameters:
- visiblebool
Visibility flag.
Examples using the class¶
Estimate a GEV on the Port Pirie sea-levels data
Estimate a GEV on the Fremantle sea-levels data
Estimate a GEV on race times data