arnaud-ma/StochasticWeatherGenerators.jl
A Julia package to define, fit and generate from Stochastic Weather Generators
StochasticWeatherGenerators.jl
A Julia package to define, fit and generate from Stochastic Weather Generators (SWG).
It provides the interface to the models and data.
To install it, just add it as any other Julia package, i.e. in the Julia REPL:
import Pkg
Pkg.add("StochasticWeatherGenerators")
# or
pkg> add StochasticWeatherGeneratorsStochastic Weather Generators
Stochastic Weather Generators (SWGs) are statistical tools that create realistic sequences of weather data by mimicking patterns found in observations. They are used to study climate variability and provide synthetic data for impact models in fields like hydrology and agriculture.
For more details, see the documentation or the IPCC note on weather generators.
** Original idea from @caroline-cognot. Thanks to the Makie team for helping on the implementation.
Models
Currently, the package offers:
-
The daily multisite rainfall SWG WGEN model proposed in Multisite Generalization of a Daily Stochastic Precipitation Generation Model by Wilks, D. S.
-
The daily multisite rainfall SWG SHHMM model proposed in the Interpretable seasonal multisite hidden Markov model for stochastic rain generation in France paper. This SWG relies on a "Seasonal Autoregressive Hidden Markov Models" (SHMM) with interpretable hidden states. Note that the seasonal models HMM, AR etc are currently implemented in a separate package SmoothPeriodicStatsModels.jl.
-
The possibility to add stations to the SHMM and variables with respect to the hidden states. In particular, a multisite SWG with 5 weather variables (Rain, Temperature Max, Temperature Min, Evapotranspiration, Solar Irradiance) was tested. The structure of the added variables is very simplistic but does the job for the proof of concept. See the associated tutorial in the documentation. This was used to generate a Hackathon dataset.
Important
The objective of this package is not only to show my model, but also to propose several classic (and newer) SWG models. Hence, feel free to open an issue or open a PR with ideas and models.
This would allow easy model comparison and, in some cases, combination.
I'll try to implement the simple (and historic) model, i.e. the Richardson - Water resources research, 1981.
Go check the documentation and the fully reproducible tutorial associated with the paper.