Model Validation

Given the centrality of auto- and cross-correlation functions in model validation, dymoval provides a class XCorrelation. Furthermore, it also provides a ValidationSession to cope with simulation results.

XCorrelation class

Constructor

XCorrelation(name, X, Y[, nlags, ...])

Cross-correlation of two signals X and Y.

Attributes

XCorrelation.name

XCorrelation object name.

XCorrelation.kind

Kind of the XCorrelation object.

XCorrelation.R

Auto- or cross-correlation array.

Methods

XCorrelation.estimate_whiteness([...])

Return the whiteness estimate based on the selected statistics.

XCorrelation.plot()

Plot the \(p imes q\) cross-correlation functions contained in R.

ValidationSession class

Constructor

ValidationSession(name, validation_dataset)

The ValidationSession class is used to validate models against a given dataset.

Attributes

ValidationSession.name

ValidationSession object name.

ValidationSession.dataset

The reference Dataset class object.

ValidationSession.outcome

Validation outcome.

ValidationSession.simulations_names

Names of the stored simulations.

ValidationSession.validation_thresholds

Input-residuals cross-correlation arrays.

ValidationSession.Ruu

Input auto-correlation arrays.

ValidationSession.Ree

Residuals auto-correlation arrays.

ValidationSession.Rue

Input-residuals cross-correlation arrays.

Methods

ValidationSession.append_simulation(...)

Append simulation results.

ValidationSession.drop_simulations(*sims)

Drop simulation results from the validation session object.

ValidationSession.plot_simulations([...])

Plot the stored simulation results.

ValidationSession.plot_residuals([...])

Plot the residuals auto- and cross-correlation functions.

ValidationSession.simulation_signals_list(...)

Return the signal name list of a given simulation.

ValidationSession.clear()

Remove all the stored simulation results in the current ValidationSession object.

ValidationSession.trim([tin, tout, verbosity])

Trim the Validation session ValidationSession object.

Functions

rsquared(x, y)

Return the \(R^2\) value of two signals.

compute_statistic(data[, statistic, weights])

Compute the statistic of a sequence of numbers.

whiteness_level(data[, data_bandwidths, ...])

Estimate the whiteness of the signal data.

validate_models(measured_in, measured_out, ...)

Validate models based on measured and simulated data.