GWEX

R 패키지 메타데이터와 수집 신호를 모아 봅니다.

Packages / CRAN / GWEX

GWEX

v1.1.3
Repository CRANLicense GPL-3Lifecycle activeNeeds compilation yes
DOI
10.32614/CRAN.package.GWEX

Core Signals

첫 화면에서 판단해야 할 수집 신호를 먼저 배치합니다.

0
표시할 핵심 신호가 없습니다.

Supported Backends

DESCRIPTION에서 감지한 backend 관련 package입니다.

0
backend package 신호가 없습니다.

Quick Facts

기본 메타데이터를 작은 카드와 토큰으로 압축합니다.

profile
Repository
CRAN
Version
1.1.3
License
GPL-3
Lifecycle
active
Needs compilation
yes
Last observed
2026-05-30
CRAN
cran.r-project.org/package=GWEX

Build fields

LinkingTo
2
RcppRcppArmadillo

수집 소스별 패키지 정보

1개 소스
CRAN
1.1.3
2026-05-30
License
GPL-3
Depends
R (>= 2.10)
Imports
Rcpp (>= 1.0.11), EnvStats, MASS, mvtnorm, nleqslv, fGarch, parallel, abind, foreach, doParallel, Renext, lmomco, methods, stats
LinkingTo
Rcpp, RcppArmadillo
Needs compilation
yes
Lifecycle
active
Last observed
2026-05-30 10:45:11

이 패키지가 의존하는 패키지

5개 표시전체 16개
PackageTypeSpec
abind
CRAN · 1.1.3 · 2026-05-30
Importsabind
doParallel
CRAN · 1.1.3 · 2026-05-30
ImportsdoParallel
EnvStats
CRAN · 1.1.3 · 2026-05-30
ImportsEnvStats
fGarch
CRAN · 1.1.3 · 2026-05-30
ImportsfGarch
foreach
CRAN · 1.1.3 · 2026-05-30
Importsforeach
1 / 4

이 패키지를 쓰는 패키지

0개 표시전체 0개
PackageTypeSpec
표시할 dependency edge가 없습니다.
1 / 1

패키지 페이지

All links
31
Repository
CRAN
Version
1.1.3
Collected
2026-05-26 00:08:04
Package page
https://cran.r-project.org/web/packages/GWEX/index.html
DOI
10.32614/CRAN.package.GWEX
CRAN checks
https://cran.r-project.org/web/checks/check_results_GWEX.html
README
https://cran.r-project.org/web/packages/GWEX/readme/README.html
Reference HTML
https://cran.r-project.org/web/packages/GWEX/refman/GWEX.html
Reference PDF
https://cran.r-project.org/web/packages/GWEX/GWEX.pdf
Source package
https://cran.r-project.org/src/contrib/GWEX_1.1.3.tar.gz
Archive
https://CRAN.R-project.org/src/contrib/Archive/GWEX
Page fields
Author
Guillaume Evin [aut, cre]
CRAN Checks
GWEX results
DOI
10.32614/CRAN.package.GWEX
License
GPL-3
LinkingTo
Rcpp , RcppArmadillo
Maintainer
Guillaume Evin <guillaume.evin at inrae.fr>
Materials
README
NeedsCompilation
yes
Old Sources
GWEX archive
Package Source
GWEX_1.1.3.tar.gz
Published
2024-02-02
Reference Manual
GWEX.html , GWEX.pdf
Version
1.1.3
Windows Binaries
r-devel: GWEX_1.1.3.zip , r-release: GWEX_1.1.3.zip , r-oldrel: GWEX_1.1.3.zip
MacOS Binaries
r-release (arm64): GWEX_1.1.3.tgz , r-oldrel (arm64): GWEX_1.1.3.tgz , r-release (x86_64): GWEX_1.1.3.tgz , r-oldrel (x86_64): GWEX_1.1.3.tgz
Version
1.1.3
LinkingTo
Rcpp , RcppArmadillo
Published
2024-02-02
DOI
10.32614/CRAN.package.GWEX
Author
Guillaume Evin [aut, cre]
Maintainer
Guillaume Evin <guillaume.evin at inrae.fr>
License
GPL-3
NeedsCompilation
yes
Materials
README
CRAN Checks
GWEX results
Reference Manual
GWEX.html , GWEX.pdf
Package Source
GWEX_1.1.3.tar.gz
Windows Binaries
r-devel: GWEX_1.1.3.zip , r-release: GWEX_1.1.3.zip , r-oldrel: GWEX_1.1.3.zip
MacOS Binaries
r-release (arm64): GWEX_1.1.3.tgz , r-oldrel (arm64): GWEX_1.1.3.tgz , r-release (x86_64): GWEX_1.1.3.tgz , r-oldrel (x86_64): GWEX_1.1.3.tgz
Old Sources
GWEX archive
Page sections 3
Documentation
Heading
Documentation
Links
[{"label":"GWEX.html","section":"","type":"","url":"https://cran.r-project.org/web/packages/GWEX/refman/GWEX.html"},{"label":"GWEX.pdf","section":"","type":"","url":"https://cran.r-project.org/web/packages/GWEX/GWEX.pdf"}]
Text
Reference manual: GWEX.html , GWEX.pdf
Downloads
Heading
Downloads
Links
[{"label":"GWEX_1.1.3.tar.gz","section":"","type":"","url":"https://cran.r-project.org/src/contrib/GWEX_1.1.3.tar.gz"},{"label":"GWEX_1.1.3.zip","section":"","type":"","url":"https://cran.r-project.org/bin/windows/contrib/4.7/GWEX_1.1.3.zip"},{"label":"GWEX_1.1.3.zip","section":"","type":"","url":"https://cran.r-project.org/bin/windows/contrib/4.6/GWEX_1.1.3.zip"},{"label":"GWEX_1.1.3.zip","section":"","type":"","url":"https://cran.r-project.org/bin/windows/contrib/4.5/GWEX_1.1.3.zip"},{"label":"GWEX_1.1.3.tgz","section":"","type":"","url":"https://cran.r-project.org/bin/macosx/sonoma-arm64/contrib/4.6/GWEX_1.1.3.tgz"},{"label":"GWEX_1.1.3.tgz","section":"","type":"","url":"https://cran.r-project.org/bin/macosx/big-sur-arm64/contrib/4.5/GWEX_1.1.3.tgz"},{"label":"GWEX_1.1.3.tgz","section":"","type":"","url":"https://cran.r-project.org/bin/macosx/big-sur-x86_64/contrib/4.6/GWEX_1.1.3.tgz"},{"label":"GWEX_1.1.3.tgz","section":"","type":"","url":"https://cran.r-project.org/bin/macosx/big-sur-x86_64/contrib/4.5/GWEX_1.1.3.tgz"},{"label":"GWEX archive","section":"","type":"","url":"https://CRAN.R-project.org/src/contrib/Archive/GWEX"}]
Text
Package source: GWEX_1.1.3.tar.gz Windows binaries: r-devel: GWEX_1.1.3.zip , r-release: GWEX_1.1.3.zip , r-oldrel: GWEX_1.1.3.zip macOS binaries: r-release (arm64): GWEX_1.1.3.tgz , r-oldrel (arm64): GWEX_1.1.3.tgz , r-release (x86_64): GWEX_1.1.3.tgz , r-oldrel (x86_64): GWEX_1.1.3.tgz Old sources: GWEX archive
Linking
Heading
Linking
Links
[{"label":"https://CRAN.R-project.org/package=GWEX","section":"","type":"","url":"https://CRAN.R-project.org/package=GWEX"}]
Text
Please use the canonical form https://CRAN.R-project.org/package=GWEX to link to this page.
Materials 1
Documentation 2
Downloads 9
All page links 31

패키지 문서 원문

3 artifacts
field
README
CRAN · 1.1.3 · Materials · text/html · 786 · 2026-05-07
Title
README
Label
README
Text content
Text content
README code{white-space: pre-wrap;} span.smallcaps{font-variant: small-caps;} span.underline{text-decoration: underline;} div.column{display: inline-block; vertical-align: top; width: 50%;} div.hanging-indent{margin-left: 1.5em; text-indent: -1.5em;} ul.task-list{list-style: none;} GWEX Multi-Site Stochastic Models for Daily Precipitation and Temperature
reference_manual_html
Reference manual HTML
CRAN · 1.1.3 · Documentation · text/html · 81,037 · 2026-05-07
Title
Help for package GWEX
Label
Reference manual HTML
Text content
Text content
Help for package GWEX const macros = { "\\R": "\\textsf{R}", "\\mbox": "\\text", "\\code": "\\texttt"}; function processMathHTML() { var l = document.getElementsByClassName('reqn'); for (let e of l) { katex.render(e.textContent, e, { throwOnError: false, macros }); } return; } Package {GWEX} Contents EGPD.GI.fPWM EGPD.GI.fit.PWM Gwex-class GwexFit-class GwexObs GwexObs-class GwexSim-class PWM.EGPD.GI QtransMat2Array agg.matrix autocor.emp.int cor.emp.int cor.emp.occ cor.obs.occ dailyPrecipGWEX dailyTemperGWEX disag.3D.to.1D dist.functions.EGPD.GI dry.day.frequency find.autocor find.omega find.zeta fit.GWex.prec fit.MAR1.amount fit.copula.amount fit.margin.cdf fitGwexModel functions.EGPD.GI get.M0 get.df.Student get.emp.cdf.matrix get.list.month get.list.season get.listOption get.mat.omega get.period.fitting.month get.vec.autocor getGwexFitPrec infer.autocor.amount infer.dep.amount infer.mat.omega joint.proba.occ lagTransProbaMatrix lagTransProbaVector mask.GWex.Yt modify.cor.matrix month2season print,Gwex-method show,Gwex-method sim.GWex.Yt sim.GWex.Yt.Pr sim.GWex.Yt.Pr.get.param sim.GWex.occ sim.GWex.prec.1it sim.Zt.MAR sim.Zt.Spatial simGwexModel simPrecipOcc unif.to.prec wet.day.frequency Type: Package Date: 2024-02-02 License: GPL-3 Title: Multi-Site Stochastic Models for Daily Precipitation and Temperature Version: 1.1.3 Author: Guillaume Evin [aut, cre] Maintainer: Guillaume Evin <guillaume.evin@inrae.fr> Imports: Rcpp (≥ 1.0.11), EnvStats, MASS, mvtnorm, nleqslv, fGarch, parallel, abind, foreach, doParallel, Renext, lmomco, methods, stats LinkingTo: Rcpp, RcppArmadillo Description: Application of multi-site models for daily precipitation and temperature data. This package is designed for an application to 105 precipitation and 26 temperature gauges located in Switzerland. It applies fitting procedures and provides weather generators described in the following references: - Evin, G., A.-C. Favre, and B. Hingray. (2018) < doi:10.5194/hess-22-655-2018 >. - Evin, G., A.-C. Favre, and B. Hingray. (2018) < doi:10.1007/s00704-018-2404-x >. Depends: R (≥ 2.10) Encoding: UTF-8 LazyData: true RoxygenNote: 7.2.3 NeedsCompilation: yes Packaged: 2024-02-02 08:47:58 UTC; eving Repository: CRAN Date/Publication: 2024-02-02 09:00:02 UTC EGPD.GI.fPWM Description Parameter estimation of the unified EGPD distribution with the PWM method. Set of equations which have to be equal to zero Usage EGPD.GI.fPWM(par, pwm, xi) Arguments par vector of parameters kappa,sig,xi pwm set of probability weighted moments of order 0, 1 and 2 xi shape parameter Value differences between expected and target weighted moments Author(s) Guillaume Evin EGPD.GI.fit.PWM Description Parameter estimation of the unified EGPD distribution with the PWM method. Numerical solver of the system of nonlinear equations Usage EGPD.GI.fit.PWM(x, xi = 0.05) Arguments x vector of parameters kappa,sig xi shape parameter Value estimated parameters kappa, sig, xi Author(s) Guillaume Evin Class Gwex Description Defines a generic Gwex object. GWex objects contain two slots: - the version ('vX.X.X') - the type of variable ('Prec' or 'Temp') Author(s) Guillaume Evin Class GwexFit Description Defines a GwexFit object which is a Gwex object containing 'fit', a list containing the fitted parameters, and 'p', the number of stations. See fitGwexModel for some examples. Author(s) Guillaume Evin Constructor Description Constructor of class [ GwexObs ] Usage GwexObs(variable, date, obs) Arguments variable 'Prec' or 'Temp' date vector of class 'Date' obs matrix nTime x nStations of observations Value An object of class [ GwexObs ] Examples # Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with precipitation data myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX) # print GwexObs object myObsPrec # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # print GwexObs object myObsTemp Class GwexObs Description Defines a GwexObs object which is a Gwex object containing dates and a matrix of observations. Author(s) Guillaume Evin Examples # Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with precipitation data myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX) # print GwexObs object myObsPrec # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # print GwexObs object myObsTemp Defines a GwexSim object which is a Gwex object containing 'sim', an array containing the simulations, and 'dates', a vector of dates. See simGwexModel for some examples. Description Defines a GwexSim object which is a Gwex object containing 'sim', an array containing the simulations, and 'dates', a vector of dates. See simGwexModel for some examples. Author(s) Guillaume Evin EGPD.GI.mu0, EGPD.GI.mu1, EGPD.GI.mu2 Description Probability Weighted Moments of order 0, 1 and 2 of the unified EGPD distribution Usage EGPD.GI.mu0(kappa, sig, xi) EGPD.GI.mu1(kappa, sig, xi) EGPD.GI.mu2(kappa, sig, xi) Arguments kappa transformation parameter greater than 0 sig Scale parameter xi Shape parameter Value Probability Weighted Moments Author(s) Guillaume Evin QtransMat2Array Description reshape Qtrans.mat to an array Usage QtransMat2Array(n, p, Qtrans.mat) Arguments n matrix of precipitation p number of stations Qtrans.mat transition probabilities, 2 x ncomb matrix Value array array of transition probabilities with dimension n x p x n.comb Author(s) Guillaume Evin agg.matrix Description Simple accumulation of a matrix of precipitation Usage agg.matrix(mat, k, average = F) Arguments mat matrix nDates x nStations to be aggregated k number of days for the accumulation average logical: should we average over the different periods (default=F) Value aggregated matrix Author(s) Guillaume Evin autocor.emp.int Description Finds empirical autocorrelations (lag-1) between intensities corresponding to a degree of autocorrelation of an AR(1) process Usage autocor.emp.int(rho, nChainFit, Xt, parMargin, typeMargin) Arguments rho autocorrelation of the AR(1) process nChainFit number of simulated variates Xt simulated occurrences, nChainFit x 2 matrix parMargin parameters of the margins 2 x 3 typeMargin type of marginal distribution: 'EGPD' or 'mixExp' Value scalar correlation between simulated intensities Author(s) Guillaume Evin cor.emp.int Description Finds observed correlations between intensities corresponding to a degree of correlation of Gaussian multivariate random numbers Usage cor.emp.int(zeta, nChainFit, Xt, parMargin, typeMargin) Arguments zeta correlation of Gaussian multivariates nChainFit number of simulated variates Xt simulated occurrences, n x 2 matrix parMargin parameters of the margins 2 x 3 typeMargin type of marginal distribution: 'EGPD' or 'mixExp' Value scalar correlation between simulated intensities Author(s) Guillaume Evin cor.emp.occ Description Finds observed correlations between occurrences corresponding to a degree of correlation of Gaussian multivariate random numbers Usage cor.emp.occ(w, Qtrans.mat, mat.comb, nLag, nChainFit, myseed = 1) Arguments w correlation of Gaussian multivariates Qtrans.mat transition probabilities, 2 x ncomb matrix mat.comb matrix of logical: ncomb x nlag nLag order of the Markov chain nChainFit number of simulated variates myseed seed of random variates Value scalar correlation between occurrences Author(s) Guillaume Evin cor.obs.occ Description provide observed correlations between occurrences for all pairs of stations see Mhanna et al. (2012) Usage cor.obs.occ(pi00, pi0, pi1) Arguments pi00 joint probability of having d
section
GWEX.pdf
CRAN · 1.1.3 · Documentation · application/pdf · 207,663 · 2026-05-07
Title
GWEX.pdf
Label
GWEX.pdf

Reference for GWEX (1.1.3)

60개 topic
EGPD.GI.fPWM
CRAN · 1.1.3 · GWEX/man/EGPD.GI.fPWM.Rd · 2026-05-07

Parameter estimation of the unified EGPD distribution with the PWM method. Set of equations which have to be equal to zero

Aliases
EGPD.GI.fPWM
Usage
EGPD.GI.fPWM(par, pwm, xi)
Arguments
par
vector of parameters kappa,sig,xi
pwm
set of probability weighted moments of order 0, 1 and 2
xi
shape parameter
Value
differences between expected and target weighted moments
Author
Guillaume Evin
EGPD.GI.fit.PWM
CRAN · 1.1.3 · GWEX/man/EGPD.GI.fit.PWM.Rd · 2026-05-07

Parameter estimation of the unified EGPD distribution with the PWM method. Numerical solver of the system of nonlinear equations

Aliases
EGPD.GI.fit.PWM
Usage
EGPD.GI.fit.PWM(x, xi = 0.05)
Arguments
x
vector of parameters kappa,sig
xi
shape parameter
Value
estimated parameters kappa, sig, xi
Author
Guillaume Evin
Gwex-class
Class Gwex
CRAN · 1.1.3 · class · GWEX/man/Gwex-class.Rd · 2026-05-07

Defines a generic 4classGwex object. GWex objects contain two slots: - the version ('vX.X.X') - the type of variable ('Prec' or 'Temp')

Aliases
Gwex-class
Author
Guillaume Evin
GwexFit-class
Class GwexFit
CRAN · 1.1.3 · class · GWEX/man/GwexFit-class.Rd · 2026-05-07

Defines a 4classGwexFit object which is a 4classGwex object containing 'fit', a list containing the fitted parameters, and 'p', the number of stations. See [GWEX]fitGwexModel for some examples.

Aliases
GwexFit-class
Author
Guillaume Evin
GwexObs
Constructor
CRAN · 1.1.3 · GWEX/man/GwexObs.Rd · 2026-05-07

Constructor of class [4classGwexObs]

Aliases
GwexObs
Usage
GwexObs(variable, date, obs)
Arguments
variable
'Prec' or 'Temp'
date
vector of class 'Date'
obs
matrix nTime x nStations of observations
Value
An object of class [4classGwexObs]
Examples
# Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with precipitation data myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX) # print GwexObs object myObsPrec # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # print GwexObs object myObsTemp
GwexObs-class
Class 4classGwexObs
CRAN · 1.1.3 · class · GWEX/man/GwexObs-class.Rd · 2026-05-07

Defines a 4classGwexObs object which is a 4classGwex object containing dates and a matrix of observations.

Aliases
GwexObs-class
Examples
# Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with precipitation data myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX) # print GwexObs object myObsPrec # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # print GwexObs object myObsTemp
Author
Guillaume Evin
GwexSim-class
Defines a 4classGwexSim object which is a 4classGwex object containing 'sim', an array containing the simulations, and '...
CRAN · 1.1.3 · class · GWEX/man/GwexSim-class.Rd · 2026-05-07

Defines a 4classGwexSim object which is a 4classGwex object containing 'sim', an array containing the simulations, and 'dates', a vector of dates. See [GWEX]simGwexModel for some examples.

Aliases
GwexSim-class
Author
Guillaume Evin
PWM.EGPD.GI
EGPD.GI.mu0, EGPD.GI.mu1, EGPD.GI.mu2
CRAN · 1.1.3 · GWEX/man/PWM.EGPD.GI.Rd · 2026-05-07

Probability Weighted Moments of order 0, 1 and 2 of the unified EGPD distribution

Aliases
PWM.EGPD.GIEGPD.GI.mu0EGPD.GI.mu1EGPD.GI.mu2
Usage
EGPD.GI.mu0(kappa, sig, xi) EGPD.GI.mu1(kappa, sig, xi) EGPD.GI.mu2(kappa, sig, xi)
Arguments
kappa
transformation parameter greater than 0
sig
Scale parameter
xi
Shape parameter
Value
Probability Weighted Moments
Author
Guillaume Evin
QtransMat2Array
CRAN · 1.1.3 · GWEX/man/QtransMat2Array.Rd · 2026-05-07

reshape Qtrans.mat to an array

Aliases
QtransMat2Array
Usage
QtransMat2Array(n, p, Qtrans.mat)
Arguments
n
matrix of precipitation
p
number of stations
Qtrans.mat
transition probabilities, 2 x ncomb matrix
Value
arrayarray of transition probabilities with dimension n x p x n.comb
Author
Guillaume Evin
agg.matrix
CRAN · 1.1.3 · GWEX/man/agg.matrix.Rd · 2026-05-07

Simple accumulation of a matrix of precipitation

Aliases
agg.matrix
Usage
agg.matrix(mat, k, average = F)
Arguments
mat
matrix nDates x nStations to be aggregated
k
number of days for the accumulation
average
logical: should we average over the different periods (default=F)
Value
aggregated matrix
Author
Guillaume Evin
autocor.emp.int
CRAN · 1.1.3 · GWEX/man/autocor.emp.int.Rd · 2026-05-07

Finds empirical autocorrelations (lag-1) between intensities corresponding to a degree of autocorrelation of an AR(1) process

Aliases
autocor.emp.int
Usage
autocor.emp.int(rho, nChainFit, Xt, parMargin, typeMargin)
Arguments
rho
autocorrelation of the AR(1) process
nChainFit
number of simulated variates
Xt
simulated occurrences, nChainFit x 2 matrix
parMargin
parameters of the margins 2 x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
Value
scalarcorrelation between simulated intensities
Author
Guillaume Evin
cor.emp.int
CRAN · 1.1.3 · GWEX/man/cor.emp.int.Rd · 2026-05-07

Finds observed correlations between intensities corresponding to a degree of correlation of Gaussian multivariate random numbers

Aliases
cor.emp.int
Usage
cor.emp.int(zeta, nChainFit, Xt, parMargin, typeMargin)
Arguments
zeta
correlation of Gaussian multivariates
nChainFit
number of simulated variates
Xt
simulated occurrences, n x 2 matrix
parMargin
parameters of the margins 2 x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
Value
scalarcorrelation between simulated intensities
Author
Guillaume Evin
cor.emp.occ
CRAN · 1.1.3 · GWEX/man/cor.emp.occ.Rd · 2026-05-07

Finds observed correlations between occurrences corresponding to a degree of correlation of Gaussian multivariate random numbers

Aliases
cor.emp.occ
Usage
cor.emp.occ(w, Qtrans.mat, mat.comb, nLag, nChainFit, myseed = 1)
Arguments
w
correlation of Gaussian multivariates
Qtrans.mat
transition probabilities, 2 x ncomb matrix
mat.comb
matrix of logical: ncomb x nlag
nLag
order of the Markov chain
nChainFit
number of simulated variates
myseed
seed of random variates
Value
scalarcorrelation between occurrences
Author
Guillaume Evin
cor.obs.occ
CRAN · 1.1.3 · GWEX/man/cor.obs.occ.Rd · 2026-05-07

provide observed correlations between occurrences for all pairs of stations see Mhanna et al. (2012)

Aliases
cor.obs.occ
Usage
cor.obs.occ(pi00, pi0, pi1)
Arguments
pi00
joint probability of having dry states
pi0
probability of having a dry state
pi1
probability of having a wet state
Value
scalarmatrix of observed correlations
Author
Guillaume Evin
References
Mhanna, Muamaraldin, and Willy Bauwens. “A Stochastic Space-Time Model for the Generation of Daily Rainfall in the Gaza Strip.” International Journal of Climatology 32, no. 7 (June 15, 2012): 1098–1112. doi:10.1002/joc.2305.
dailyPrecipGWEX
daily observations of precipitation data
CRAN · 1.1.3 · data · GWEX/man/dailyPrecipGWEX.Rd · 2026-05-07

Example of daily observations of precipitation (mm) for three fictive stations, for a period of ten years.

Aliases
dailyPrecipGWEX
Keywords
datasets
Usage
data(dailyPrecipGWEX)
Format
matrix of Observed precipitation: 3652 days x 3 stations
Author
Guillaume Evin guillaume.evin@irstea.fr
References
Evin, G., A.-C. Favre, and B. Hingray. 2018. “Stochastic Generation of Multi-Site Daily Precipitation Focusing on Extreme Events". Hydrol. Earth Syst. Sci. 22 (1): 655–672.
dailyTemperGWEX
daily observations of temperature data
CRAN · 1.1.3 · data · GWEX/man/dailyTemperGWEX.Rd · 2026-05-07

Example of daily observations of temperature (mm) for three fictive stations, for a period of ten years.

Aliases
dailyTemperGWEX
Keywords
datasets
Usage
data(dailyTemperGWEX)
Format
matrix of Observed temperature: 3652 days x 3 stations
Author
Guillaume Evin guillaume.evin@irstea.fr
References
Evin G., A.C. Favre, and B. Hingray. 2018. Stochastic Generators of Multi Site Daily Temperature: Comparison of Performances in Various Applications. Theoretical and Applied Climatology.
disag.3D.to.1D
CRAN · 1.1.3 · GWEX/man/disag.3D.to.1D.Rd · 2026-05-07

disag.3D.to.1D

Aliases
disag.3D.to.1D
Usage
disag.3D.to.1D(Yobs, YObsAgg, mObsAgg, YSimAgg, mSimAgg, prob.class)
Arguments
Yobs
matrix of observed intensities at 24h: (nTobs*3) x nStation
YObsAgg
matrix of observed 3-day intensities: nTobs x nStation
mObsAgg
vector of season corresponding to YobsAgg
YSimAgg
matrix of simulated intensities per 3-day period: nTsim x nStation
mSimAgg
vector of season corresponding to the period simulated
prob.class
vector of probabilities indicating class of "similar" mean intensities
Value
listYsim matrix of disagregated daily precipitation, codeDisag matrix of disagregation codes
Author
Guillaume Evin
dist.functions.EGPD.GI
dEGPD.GI, pEGPD.GI, qEGPD.GI, rEGPD.GI
CRAN · 1.1.3 · GWEX/man/dist.functions.EGPD.GI.Rd · 2026-05-07

Density function, distribution function, quantile function, random generation for the unified EGPD distribution

Aliases
dist.functions.EGPD.GIdEGPD.GIpEGPD.GIqEGPD.GIrEGPD.GI
Usage
dEGPD.GI(x, kappa, sig, xi) pEGPD.GI(x, kappa, sig, xi) qEGPD.GI(p, kappa, sig, xi) rEGPD.GI(n, kappa, sig, xi)
Arguments
x
Vector of quantiles
kappa
transformation parameter greater than 0
sig
Scale parameter
xi
Shape parameter
p
Vector of probabilities
n
Number of observations
Value
dEGPD.GI gives the density function, pEGPD.GI gives the distribution function, qEGPD.GI gives the quantile function, and rEGPD.GI generates random deviates.
Author
Guillaume Evin
dry.day.frequency
CRAN · 1.1.3 · GWEX/man/dry.day.frequency.Rd · 2026-05-07

Estimate the dry day frequency (proportion of dry days) for all stations

Aliases
dry.day.frequency
Usage
dry.day.frequency(mat.prec, th)
Arguments
mat.prec
matrix of precipitation (possibly for one month/period)
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
Value
vector of numericdry day frequencies
Author
Guillaume Evin
find.autocor
CRAN · 1.1.3 · GWEX/man/find.autocor.Rd · 2026-05-07

finds the autocorrelation leading to observed autocorrelation

Aliases
find.autocor
Usage
find.autocor(autocor.emp, nChainFit, Xt, parMargin, typeMargin)
Arguments
autocor.emp
target correlation between intensities
nChainFit
number of simulations
Xt
simulated occurrences, nChainFit x 2 matrix
parMargin
parameters of the margins 2 x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
Value
scalarneeded correlation
Author
Guillaume Evin
find.omega
CRAN · 1.1.3 · GWEX/man/find.omega.Rd · 2026-05-07

finds the correlation between normal variates leading to correlation between occurrences

Aliases
find.omega
Usage
find.omega(rho.emp, Qtrans.mat, mat.comb, nLag, nChainFit)
Arguments
rho.emp
target correlation between occurences
Qtrans.mat
transition probabilities, 2 x ncomb matrix
mat.comb
matrix of logical: ncomb x nlag
nLag
order of the Markov chain
nChainFit
length of the simulated chains used during the fitting
Value
scalarneeded correlation
Author
Guillaume Evin
find.zeta
CRAN · 1.1.3 · GWEX/man/find.zeta.Rd · 2026-05-07

finds the correlation between normal variates leading to correlation between intensities

Aliases
find.zeta
Usage
find.zeta(eta.emp, nChainFit, Xt, parMargin, typeMargin)
Arguments
eta.emp
target correlation between intensities
nChainFit
number of simulations
Xt
simulated occurrences, n x 2 matrix
parMargin
parameters of the margins 2 x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
Value
scalarneeded correlation
Author
Guillaume Evin
fit.GWex.prec
CRAN · 1.1.3 · GWEX/man/fit.GWex.prec.Rd · 2026-05-07

estimate all the parameters for the G-Wex model of precipitation

Aliases
fit.GWex.prec
Usage
fit.GWex.prec(objGwexObs, parMargin, listOption = NULL)
Arguments
objGwexObs
object of class 4classGwexObs
parMargin
if not NULL, list where each element parMargin[[iM]] corresponds to a month iM=1...12 and contains a matrix nStation x 3 of estimated parameters of the marginal distributions (EGPD or mixture of exponentials)
listOption
list with the following fields: th: threshold value in mm above which precipitation observations are considered to be non-zero (=0.2 by default) nLag: order of he Markov chain for the transitions between dry and wet states (=2 by default) typeMargin: 'EGPD' (Extended GPD) or 'mixExp' (Mixture of Exponentials). 'EGPD' by default copulaInt: 'Gaussian' or 'Student': type of dependence for amounts (='Student' by default) isMAR: logical value, do we apply a Autoregressive Multivariate Autoregressive model (order 1) =TRUE by default is3Damount: logical value, do we apply the model on 3D-amount. =FALSE by default nChainFit: integer, length of the runs used during the fitting procedure. =100000 by default nCluster: integer, number of clusters which can be used for the parallel computation
Value
a list containing the list of options listOption and the list of estimated parameters listPar. The parameters of the occurrence process are contained in parOcc and the parameters related to the precipitation amounts are contained in parInt. Each type of parameter is a list containing the estimates for each month. In parOcc, we find: p01: For each station, the probability of transition from a dry state to a wet state. p11: For each station, the probability of staying in a wet state. list.pr.state: For each station, the probabilities of transitions for a Markov chain with lag p. list.mat.omega: The spatial correlation matrix of occurrences (see Evin et al., 2018). In parInt, we have: parMargin: list of matrices nStation x nPar of parameters for the marginal distributions (one element per Class). cor.int: Matrices nStation x nStation M_0, A, _Z representing the spatial and temporal correlations between all the stations (see Evin et al., 2018). For the Student copula, dfStudent indicates the parameter.
Author
Guillaume Evin
References
Evin, G., A.-C. Favre, and B. Hingray. 2018. 'Stochastic Generation of Multi-Site Daily Precipitation Focusing on Extreme Events.' Hydrol. Earth Syst. Sci. 22 (1): 655-672. doi.org/10.5194/hess-22-655-2018.
fit.MAR1.amount
CRAN · 1.1.3 · GWEX/man/fit.MAR1.amount.Rd · 2026-05-07

estimate parameters which control the dependence between intensities with a MAR(1) process

Aliases
fit.MAR1.amount
Usage
fit.MAR1.amount(P.mat, isPeriod, th, copulaInt, M0, A)
Arguments
P.mat
precipitation matrix
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
copulaInt
type of dependance between inter-site amounts: 'Gaussian' or 'Student'
M0
covariance matrix of gaussianized prec. amounts for all pairs of stations
A
Matrix containing the autocorrelation (temporal) correlations
Value
list with the following items M0 covariance matrix of gaussianized prec. amounts for all pairs of stations A omega correlations for all pairs of stations covZ covariance matrix of the MAR(1) process sdZ standard deviation of the diagonal elements corZ correlation matrix of the MAR(1) process dfStudent degrees of freedom for the Student copula if CopulaInt is equal to "Student"
Author
Guillaume Evin
References
Matalas, N. C. 1967. “Mathematical Assessment of Synthetic Hydrology.” Water Resources Research 3 (4): 937–45. https://doi.org/10.1029/WR003i004p00937. Bárdossy, A., and G. G. S. Pegram. 2009. “Copula Based Multisite Model for Daily Precipitation Simulation.” Hydrology and Earth System Sciences 13 (12): 2299–2314. https://doi.org/10.5194/hess-13-2299-2009.
fit.copula.amount
CRAN · 1.1.3 · GWEX/man/fit.copula.amount.Rd · 2026-05-07

estimate parameters which control the spatial dependence between intensities using a copula

Aliases
fit.copula.amount
Usage
fit.copula.amount(P.mat, isPeriod, th, copulaInt, M0)
Arguments
P.mat
precipitation matrix
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
copulaInt
type of dependence between inter-site amounts: 'Gaussian' or 'Student'
M0
covariance matrix of gaussianized prec. amounts for all pairs of stations
Value
listlist of estimates (e.g., M0, dfStudent)
Author
Guillaume Evin
fit.margin.cdf
CRAN · 1.1.3 · GWEX/man/fit.margin.cdf.Rd · 2026-05-07

estimate parameters which control the marginal distribution of precipitation amounts

Aliases
fit.margin.cdf
Usage
fit.margin.cdf(P.mat, isPeriod, th, type = c("EGPD", "mixExp"))
Arguments
P.mat
precipitation matrix
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
type
distribution: 'EGPD' or 'mixExp'
Value
matrixmatrix of estimates p x 3
Author
Guillaume Evin
fitGwexModel
fitGwexModel: fit a GWex model to observations.
CRAN · 1.1.3 · GWEX/man/fitGwexModel.Rd · 2026-05-07

fitGwexModel: fit a GWex model to observations.

Aliases
fitGwexModel
Usage
fitGwexModel(objGwexObs, parMargin = NULL, listOption = NULL)
Arguments
objGwexObs
an object of class 4classGwexObs
parMargin
(not required for temperature) list parMargin where and each element corresponds to a month (1...12) and contains a matrix nStation x 3 of pre-estimated parameters of the marginal distributions (EGPD or Mixture of Exponentials)
listOption
for precipitation, a list with the following fields: th: threshold value in mm above which precipitation observations are considered to be non-zero (=0.2 by default) nLag: order of the Markov chain for the transitions between dry and wet states (=2 by default) typeMargin: 'EGPD' (Extended GPD) or 'mixExp' (Mixture of Exponentials). 'mixExp' by default copulaInt: 'Gaussian' or 'Student': type of dependence for amounts (='Gaussian' by default) isMAR: logical value, do we apply a Autoregressive Multivariate Autoregressive model (order 1) = FALSE by default is3Damount: logical value, do we apply the model on 3D-amount. =FALSE by default nChainFit: integer, length of the runs which are generated during the fitting procedure. =100000 by default nCluster: integer, number of clusters which can be used for the parallel computation and for temperature, a list with the following fields: hasTrend: logical value, do we fit a linear trend for the long-term change, =FALSE by default objGwexPrec: object of class 4classGwexObs containing precipitation observations. If provided, we assume that temperature must be modelled and simulated according to the precipitation states 'dry' and 'wet'. For each state, a seasonal cycle is fitted (mean and sd). typeMargin: 'SGED' (default) or 'Gaussian': type of marginal distribution. depStation: 'MAR1' (default) or 'Gaussian': MAR1 (Multivariate Autoregressive model order 1) for the spatial and temporal dependence or 'Gaussian' for the spatial dependence only.
Value
Return an object of class 4classGwexFit with: p: The number of station, version: package version, variable: the type of variable, fit: a list containing the list of options listOption and the list of estimated parameters listPar.
Examples
# Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') ############################################################### # FIT THE PRECIPITATION MODEL ############################################################### # Format observations: create a Gwex object for one station only to show a quick # example. The syntax is similar for multi-site applications. myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX[,1,drop=FALSE]) # Fit precipitation model with a threshold of 0.5 mm to distinguish wet and dry # states (th) and keep default options otherwise, e.g. a Gaussian # copula for the spatial dependence (copulaInt) and a mixExp distribution for # marginal intensities ('typeMargin') myParPrec = fitGwexModel(myObsPrec,listOption=list(th=0.5)) myParPrec # print object ############################################################### # FIT THE TEMPERATURE MODEL, COND. TO PRECIPITATION ############################################################### # Format observations: create a G-Wex object myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # Fit temperature model with a long-term linear trend ('hasTrend'), Gaussian margins # ('typeMargin') and Gaussian spatial dependence ('depStation') myParTemp = fitGwexModel(myObsTemp,listOption=list(hasTrend=TRUE,typeMargin='Gaussian', depStation='Gaussian')) myParTemp # print object
Author
Guillaume Evin
functions.EGPD.GI
EGPD.pGI, EGPD.dGI, EGPD.qGI
CRAN · 1.1.3 · GWEX/man/functions.EGPD.GI.Rd · 2026-05-07

First parametric family for G(v) = v^kappa: distribution, density and quantile function

Aliases
functions.EGPD.GIEGPD.pGIEGPD.dGIEGPD.qGI
Usage
EGPD.pGI(v, kappa) EGPD.dGI(v, kappa) EGPD.qGI(p, kappa)
Arguments
v
probability
kappa
transformation parameter greater than 0
p
probability
Value
distribution, density and quantile of EGPD
Author
Guillaume Evin
get.M0
CRAN · 1.1.3 · GWEX/man/get.M0.Rd · 2026-05-07

find matrix of correlations leading to estimates cor between intensities

Aliases
get.M0
Usage
get.M0( cor.obs, infer.mat.omega.out, nLag, parMargin, typeMargin, nChainFit, isParallel )
Arguments
cor.obs
matrix p x p of observed correlations between intensities for all pairs of stations
infer.mat.omega.out
output of infer.mat.omega
nLag
order of the Markov chain
parMargin
parameters of the margins p x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
nChainFit
integer indicating the length of simulated chains
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
list with two items Xt long simulation of the wet/dry states according to the model M0 covariance matrix of gaussianized prec. amounts for all pairs of stations
Author
Guillaume Evin
get.df.Student
CRAN · 1.1.3 · GWEX/man/get.df.Student.Rd · 2026-05-07

Estimates the nu parameter (degrees of freedom) of the multivariate Student distribution when the correlation matrix Sig is given

Aliases
get.df.Student
Usage
get.df.Student(P, Sig, max.df = 20)
Arguments
P
matrix of non-zero precipitation (zero precipitation are set to NA)
Sig
correlation matrix
max.df
maximum degrees of freedom tested (default=20)
Value
nu estimate
Author
Guillaume Evin
References
McNeil et al. (2005) "Quantitative Risk Management"
get.emp.cdf.matrix
get.df.Student
CRAN · 1.1.3 · GWEX/man/get.emp.cdf.matrix.Rd · 2026-05-07

get the cdf values (empirical distribution) of positive precipitation

Aliases
get.emp.cdf.matrix
Usage
get.emp.cdf.matrix(X)
Arguments
X
matrix of positive precipitation
Value
matrix with cdf values (NA if zero precipitation)
Author
Guillaume Evin
get.list.month
CRAN · 1.1.3 · GWEX/man/get.list.month.Rd · 2026-05-07

return a vector of 3-char tags of the 12 months

Aliases
get.list.month
Usage
get.list.month()
get.list.season
CRAN · 1.1.3 · GWEX/man/get.list.season.Rd · 2026-05-07

get the vector of the four seasons c('DJF','MAM','JJA','SON')

Aliases
get.list.season
Usage
get.list.season()
Author
Guillaume Evin
get.listOption
CRAN · 1.1.3 · GWEX/man/get.listOption.Rd · 2026-05-07

get default options and check values proposed by the user

Aliases
get.listOption
Usage
get.listOption(listOption)
Arguments
listOption
list containing fields corr. to the different options. Can be NULL if no options are set
Value
listOptionlist of options
Author
Guillaume Evin
get.mat.omega
CRAN · 1.1.3 · GWEX/man/get.mat.omega.Rd · 2026-05-07

find omega correlation leading to estimates cor between occurrences

Aliases
get.mat.omega
Usage
get.mat.omega(cor.obs, Qtrans.mat, mat.comb, nLag, nChainFit, isParallel)
Arguments
cor.obs
matrix p x p of observed correlations between occurrences for all pairs of stations
Qtrans.mat
transition probabilities, 2 x ncomb matrix
mat.comb
matrix of logical: ncomb x nlag
nLag
order of the Markov chain
nChainFit
length of the simulated chains used during the fitting
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
matrixomega correlations for all pairs of stations
Author
Guillaume Evin
get.period.fitting.month
CRAN · 1.1.3 · GWEX/man/get.period.fitting.month.Rd · 2026-05-07

get.period.fitting.month

Aliases
get.period.fitting.month
Usage
get.period.fitting.month(m.char)
Arguments
m.char
3-letter name of a month (e.g. 'JAN') return the 3 indices corresponding to the 3-month period of a month ('JAN')
get.vec.autocor
CRAN · 1.1.3 · GWEX/man/get.vec.autocor.Rd · 2026-05-07

find rho autocorrelation leading to empirical estimates

Aliases
get.vec.autocor
Usage
get.vec.autocor(vec.ar1.obs, Xt, parMargin, typeMargin, nChainFit, isParallel)
Arguments
vec.ar1.obs
vector of observed autocorrelations for all stations
Xt
simulated occurrences given model parameters of wet/dry states
parMargin
parameters of the margins p x 3
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
nChainFit
integer indicating the length of the simulated chains
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
vectorvector of rho parameters to simulate the MAR process
Author
Guillaume Evin
getGwexFitPrec
CRAN · 1.1.3 · GWEX/man/getGwexFitPrec.Rd · 2026-05-07

get object GwexFit derived from the parameters replicated for each month

Aliases
getGwexFitPrec
Usage
getGwexFitPrec( listOption = NULL, p, condProbaWDstates, parMargin, vec.ar1 = NULL, M0 = NULL, mat.omega = NULL )
Arguments
listOption
list of options (see fitGwexModel)
p
number of stations
condProbaWDstates
vector of length nLag^2 of transition probabilities corresponding to the nlag possible transitions between dry/wet states expand.grid(lapply(numeric(nLag), function(x) c(F,T)))
parMargin
parameters of the margins: vector of length 3
vec.ar1
vector of observed autocorrelations for all stations
M0
M0: covariance matrix of gaussianized prec. amounts for all pairs of stations
mat.omega
mat.omega: The spatial correlation matrix of occurrences
Value
Return an object of class 4classGwexFit with: p: The number of station, version: package version, variable: the type of variable, fit: a list containing the list of options listOption and the list of estimated parameters listPar.
Examples
exFitGwexPrec = getGwexFitPrec(p=2,condProbaWDstates=c(0.7,0.3,0.2,0.1), parMargin=c(0.5,0.1,0.4),vec.ar1=rep(0.7,2),M0=rbind(c(1,0.6),c(0.6,1)), mat.omega=rbind(c(1,0.8),c(0.8,1)))
infer.autocor.amount
CRAN · 1.1.3 · GWEX/man/infer.autocor.amount.Rd · 2026-05-07

special case of infer.dep.amount where there is only one station

Aliases
infer.autocor.amount
Usage
infer.autocor.amount( P.mat, pr.state, isPeriod, nLag, th, parMargin, typeMargin, nChainFit, isMAR, isParallel )
Arguments
P.mat
precipitation matrix
pr.state
probabilities of transitions for a Markov chain with lag p.
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
nLag
order of he Markov chain for the transitions between dry and wet states (=2 by default)
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
parMargin
parameters of the margins 2 x 3
typeMargin
'EGPD' (Extended GPD) or 'mixExp' (Mixture of Exponentials). 'EGPD' by default
nChainFit
integer, length of the runs used during the fitting procedure. =100000 by default
isMAR
logical value, do we apply a Autoregressive Multivariate Autoregressive model (order 1) =TRUE by default
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
listlist of estimates (e.g., M0, dfStudent)
Author
Guillaume Evin
infer.dep.amount
CRAN · 1.1.3 · GWEX/man/infer.dep.amount.Rd · 2026-05-07

estimate parameters which control the spatial dependence between intensities using a copula

Aliases
infer.dep.amount
Usage
infer.dep.amount( P.mat, isPeriod, infer.mat.omega.out, nLag, th, parMargin, typeMargin, nChainFit, isMAR, copulaInt, isParallel )
Arguments
P.mat
precipitation matrix
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
infer.mat.omega.out
output of infer.mat.omega
nLag
order of he Markov chain for the transitions between dry and wet states (=2 by default)
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
parMargin
parameters of the margins 2 x 3
typeMargin
'EGPD' (Extended GPD) or 'mixExp' (Mixture of Exponentials). 'EGPD' by default
nChainFit
integer, length of the runs used during the fitting procedure. =100000 by default
isMAR
logical value, do we apply a Autoregressive Multivariate Autoregressive model (order 1) =TRUE by default
copulaInt
'Gaussian' or 'Student': type of dependence for amounts (='Student' by default)
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
listlist of estimates (e.g., M0, dfStudent)
Author
Guillaume Evin
infer.mat.omega
CRAN · 1.1.3 · GWEX/man/infer.mat.omega.Rd · 2026-05-07

find omega correlation leading to estimates cor between occurrences

Aliases
infer.mat.omega
Usage
infer.mat.omega(P.mat, isPeriod, th, nLag, pr.state, nChainFit, isParallel)
Arguments
P.mat
matrix of precipitation n x p
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
nLag
order of the Markov chain
pr.state
output of function lagTransProbaMatrix
nChainFit
length of the simulated chains used during the fitting
isParallel
logical: indicate computation in parallel or not (easier for debugging)
Value
A list with different objects Qtrans.mat: matrix nStation x n.comb of transition probabilites mat.comb: matrix of possible combination n.comb x nLag mat.omega: The spatial correlation matrix of occurrences (see Evin et al., 2018).
Author
Guillaume Evin
joint.proba.occ
CRAN · 1.1.3 · GWEX/man/joint.proba.occ.Rd · 2026-05-07

joint probabilities of occurrences for all pairs of stations

Aliases
joint.proba.occ
Usage
joint.proba.occ(P, th)
Arguments
P
matrix of precipitation
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
Value
listlist of joint probabilities
Author
Guillaume Evin
lagTransProbaMatrix
CRAN · 1.1.3 · GWEX/man/lagTransProbaMatrix.Rd · 2026-05-07

Estimate the transition probabilities between wet and dry states, for nlag previous days, for all stations

Aliases
lagTransProbaMatrix
Usage
lagTransProbaMatrix(mat.prec, isPeriod, th, nlag)
Arguments
mat.prec
matrix of precipitation
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
nlag
number of lag days
Value
listlist with one item per station, where each item is a matrix nLag^2 x (nLag+1) of transition probability between dry/wet state. The first nLag columns indicate the wet/dry states for the previous nLag days
Author
Guillaume Evin
lagTransProbaVector
CRAN · 1.1.3 · GWEX/man/lagTransProbaVector.Rd · 2026-05-07

Estimate the transition probabilities between wet and dry states, for nlag previous days, for one station

Aliases
lagTransProbaVector
Usage
lagTransProbaVector(vec.prec, isPeriod, th, nlag)
Arguments
vec.prec
vector nx1 of precipitation for one station
isPeriod
vector of logical n x 1 indicating the days concerned by a 3-month period
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
nlag
number of lag days
Value
matrixmatrix nLag^2 x (nLag+1) of transition probability between dry/wet state. The first nLag columns indicate the wet/dry states for the previous nLag days
Author
Guillaume Evin
mask.GWex.Yt
CRAN · 1.1.3 · GWEX/man/mask.GWex.Yt.Rd · 2026-05-07

Mask intensities where there is no occurrence

Aliases
mask.GWex.Yt
Usage
mask.GWex.Yt(Xt, Yt)
Arguments
Xt
simulated occurrences
Yt
simulated intensities
Value
matrixmatrix n x p of simulated precipitations
Author
Guillaume Evin
modify.cor.matrix
CRAN · 1.1.3 · GWEX/man/modify.cor.matrix.Rd · 2026-05-07

Modify a non-positive definite correlation matrix in order to have a positive definite matrix

Aliases
modify.cor.matrix
Usage
modify.cor.matrix(cor.matrix)
Arguments
cor.matrix
possibly non-positive definite correlation matrix
Value
positive definite correlation matrix
Author
Guillaume Evin
References
Rousseeuw, P. J. and G. Molenberghs. 1993. Transformation of non positive semidefinite correlation matrices. Communications in Statistics: Theory and Methods 22(4):965-984. Rebonato, R., & Jackel, P. (2000). The most general methodology to create a valid correlation matrix for risk management and option pricing purposes. J. Risk, 2(2), 17-26.
month2season
CRAN · 1.1.3 · GWEX/man/month2season.Rd · 2026-05-07

transform vector of months to seasons

Aliases
month2season
Usage
month2season(vecMonth)
Arguments
vecMonth
a vector of months given as integers 1:12
Author
Guillaume Evin
print,Gwex-method
print-methods: Create a method to print Gwex objects.
CRAN · 1.1.3 · GWEX/man/print-methods.Rd · 2026-05-07

print-methods: Create a method to print Gwex objects.

Aliases
print,Gwex-methodprint,GwexObs-methodprint,GwexFit-methodprint,GwexSim-method
Usage
4methodprintGwex(x) 4methodprintGwexObs(x) 4methodprintGwexFit(x) 4methodprintGwexSim(x)
Arguments
x
4classGwex object
Examples
# Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # print GwexObs object myObsTemp
show,Gwex-method
show-methods: Create a method to show Gwex objects.
CRAN · 1.1.3 · GWEX/man/show-methods.Rd · 2026-05-07

show-methods: Create a method to show Gwex objects.

Aliases
show,Gwex-methodshow,GwexObs-methodshow,GwexFit-methodshow,GwexSim-method
Usage
4methodshowGwex(object) 4methodshowGwexObs(object) 4methodshowGwexFit(object) 4methodshowGwexSim(object)
Arguments
object
4classGwex object
Examples
# Format dates corresponding to daily observations of precipitation and temperature vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') # build GwexObs object with temperature data myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # show GwexObs object myObsTemp
sim.GWex.Yt
CRAN · 1.1.3 · GWEX/man/sim.GWex.Yt.Rd · 2026-05-07

Inverse PIT: from the probability space to the precipitation space

Aliases
sim.GWex.Yt
Usage
sim.GWex.Yt(objGwexFit, vecMonth, Yt.Pr)
Arguments
objGwexFit
object of class GwexFit
vecMonth
vector of integer indicating the months
Yt.Pr
uniform variates describing dependence between inter-site amounts
Value
matrixmatrix n x p of simulated non-zero precipitation intensities
Author
Guillaume Evin
sim.GWex.Yt.Pr
CRAN · 1.1.3 · GWEX/man/sim.GWex.Yt.Pr.Rd · 2026-05-07

generate uniform variates which describe the dependence between intersite amount correlations

Aliases
sim.GWex.Yt.Pr
Usage
sim.GWex.Yt.Pr(objGwexFit, vecMonth)
Arguments
objGwexFit
object of class GwexFit
vecMonth
vector n x 1 of integer indicating the months
Value
matrixmatrix n x p of uniform dependent variates
Author
Guillaume Evin
sim.GWex.Yt.Pr.get.param
CRAN · 1.1.3 · GWEX/man/sim.GWex.Yt.Pr.get.param.Rd · 2026-05-07

get relevant parameters

Aliases
sim.GWex.Yt.Pr.get.param
Usage
sim.GWex.Yt.Pr.get.param(objGwexFit, iM)
Arguments
objGwexFit
object of class GwexFit
iM
integer indicating the month
Value
listlist of parameters
Author
Guillaume Evin
sim.GWex.occ
CRAN · 1.1.3 · GWEX/man/sim.GWex.occ.Rd · 2026-05-07

generate boolean variates which describe the dependence between intersite occurrence correlations and wet/dry persistence

Aliases
sim.GWex.occ
Usage
sim.GWex.occ(objGwexFit, vecMonth)
Arguments
objGwexFit
object of class GwexFit
vecMonth
vector n x 1 of integers indicating the months
Value
matrix of logicaloccurrences simulated
Author
Guillaume Evin
sim.GWex.prec.1it
CRAN · 1.1.3 · GWEX/man/sim.GWex.prec.1it.Rd · 2026-05-07

Simulate one scenario of precipitation from the GWex model

Aliases
sim.GWex.prec.1it
Usage
sim.GWex.prec.1it(objGwexFit, vecDates, myseed, objGwexObs, prob.class)
Arguments
objGwexFit
object of class GwexFit
vecDates
vector of continuous dates
myseed
seed of the random generation, to be fixed if the results need to be replicated
objGwexObs
optional: necessary if we need observations to simulate (e.g. disaggregation of 3-day periods)
prob.class
vector of probabilities indicating class of "similar" mean intensities
Value
matrixPrecipitation simulated for the dates contained in vec.Dates at the different stations
Author
Guillaume Evin
sim.Zt.MAR
CRAN · 1.1.3 · GWEX/man/sim.Zt.MAR.Rd · 2026-05-07

generate gaussian variates which describe the spatial and temporal dependence between the sites (MAR(1) process)

Aliases
sim.Zt.MAR
Usage
sim.Zt.MAR(PAR, copulaInt, Zprev, p)
Arguments
PAR
parameters for this class
copulaInt
'Gaussian' or 'Student'
Zprev
previous Gaussian variate
p
number of stations
Value
matrixmatrix n x p of uniform dependent variates
Author
Guillaume Evin
sim.Zt.Spatial
CRAN · 1.1.3 · GWEX/man/sim.Zt.Spatial.Rd · 2026-05-07

generate gaussian variates which describe the spatial dependence between the sites

Aliases
sim.Zt.Spatial
Usage
sim.Zt.Spatial(PAR, copulaInt, p)
Arguments
PAR
parameters for a class
copulaInt
'Gaussian' or 'Student'
p
number of stations
Value
matrixmatrix n x p of uniform dependent variates
Author
Guillaume Evin
simGwexModel
CRAN · 1.1.3 · GWEX/man/simGwexModel.Rd · 2026-05-07

Simulate from a GWex model

Aliases
simGwexModel
Usage
simGwexModel( objGwexFit, nb.rep = 10, d.start = as.Date("01011900", "%d%m%Y"), d.end = as.Date("31121999", "%d%m%Y"), objGwexObs = NULL, prob.class = c(0.5, 0.75, 0.9, 0.99), objGwexSim = NULL, nCluster = 1 )
Arguments
objGwexFit
an object of class 4classGwexFit
nb.rep
number of repetitions of scenarios
d.start
a starting date for the simulation
d.end
an ending date for the simulation
objGwexObs
optional: an object of class 4classGwexObs if we need the observations to simulate (disaggregation prec 3D -> 1D)
prob.class
vector of probabilities indicating class of "similar" mean intensities
objGwexSim
optional: an object of class 4classGwexSim if we need simulations to simulate (temp conditional to prec)
nCluster
optional, number of clusters which can be used for the parallel computation
Value
GwexSiman object of class 4classGwexSim. Contains sim (3D-array with the simulations) and a vector of dates
Examples
# vector of dates vecDates = seq(from=as.Date("01/01/2005",format="%d/%m/%Y"), to=as.Date("31/12/2014",format="%d/%m/%Y"),by='day') ############################################################### # FIT AND SIMULATE FROM THE PRECIPITATION MODEL ############################################################### # Format observations: create a G-Wex object myObsPrec = GwexObs(variable='Prec',date=vecDates,obs=dailyPrecipGWEX[,1,drop=FALSE]) # Fit GWEX precipitation model, default options except for the threshold th myParPrec = fitGwexModel(myObsPrec,listOption=list(th=0.5)) # fit model # Generate 2 scenarios for one year, using the 'GwexFit' object mySimPrec = simGwexModel(objGwexFit=myParPrec, nb.rep=2, d.start=vecDates[1], d.end=vecDates[10]) mySimPrec # print object ############################################################### # FIT AND SIMULATE FROM THE TEMPERATURE MODEL ############################################################### # Format observations: create a G-Wex object myObsTemp = GwexObs(variable='Temp',date=vecDates,obs=dailyTemperGWEX) # Fit GWEX temperature model myParTemp = fitGwexModel(myObsTemp,listOption=list(hasTrend=TRUE,typeMargin='Gaussian', depStation='Gaussian')) # Generate 2 scenarios for one year, using an existing 'GwexFit' object mySimTemp = simGwexModel(objGwexFit=myParTemp, nb.rep=2, d.start=vecDates[1], d.end=vecDates[365],objGwexObs=myObsPrec) mySimTemp # print object
Author
Guillaume Evin
simPrecipOcc
CRAN · 1.1.3 · GWEX/man/simPrecipOcc.Rd · 2026-05-07

find matrix of correlations leading to estimates cor between intensities

Aliases
simPrecipOcc
Usage
simPrecipOcc(nLag, n, pr)
Arguments
nLag
order of the Markov chain
n
integer indicating the length of simulated chains
pr
vector of probabilies corr. to the conditional transition probabilities
Value
a vector Xt of length n with values 0/1 corr. to dry/wet states
Author
Guillaume Evin
unif.to.prec
CRAN · 1.1.3 · GWEX/man/unif.to.prec.Rd · 2026-05-07

from uniform variates to precipitation variates

Aliases
unif.to.prec
Usage
unif.to.prec(pI, typeMargin, U)
Arguments
pI
vector of three parameters of the marginal distributions
typeMargin
type of marginal distribution: 'EGPD' or 'mixExp'
U
vector of uniform variates
Value
matrixmatrix of estimates p x 3
Author
Guillaume Evin
wet.day.frequency
CRAN · 1.1.3 · GWEX/man/wet.day.frequency.Rd · 2026-05-07

Estimate the wet day frequency (proportion of wet days) for all stations

Aliases
wet.day.frequency
Usage
wet.day.frequency(mat.prec, th)
Arguments
mat.prec
matrix of precipitation (possibly for one month/period)
th
threshold above which we consider that a day is wet (e.g. 0.2 mm)
Value
vector of numericwet day frequencies
Author
Guillaume Evin

버전 이력

RepositoryVersionPublishedFirst seenLast seenDocs
CRAN1.1.32026-05-292026-05-30

보안

표시할 OSV 데이터가 없습니다.

문헌 신호

표시할 OpenAlex 데이터가 없습니다.