Skip to content

Commit 334ce82

Browse files
committed
Add thselect.egp
1 parent c89aef3 commit 334ce82

10 files changed

Lines changed: 540 additions & 157 deletions

File tree

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: mev
22
Type: Package
33
Title: Modelling of Extreme Values
4-
Version: 2.0
4+
Version: 2.0.0001
55
Authors@R: c(
66
person(given="Leo", family="Belzile", role = c("aut", "cre"), email = "belzilel@gmail.com", comment = c(ORCID = "0000-0002-9135-014X")),
77
person(given="Jennifer L.", family="Wadsworth", role=c("aut")),

NAMESPACE

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ S3method(plot,eprof)
2323
S3method(plot,fr)
2424
S3method(plot,mev_adf)
2525
S3method(plot,mev_egp_retlev)
26+
S3method(plot,mev_egp_thselect)
2627
S3method(plot,mev_egp_tstab)
2728
S3method(plot,mev_extcoef)
2829
S3method(plot,mev_extremo)
@@ -51,6 +52,7 @@ S3method(plot,mev_tstab_mrl)
5152
S3method(plot,mev_xdep)
5253
S3method(print,eprof)
5354
S3method(print,mev_egp)
55+
S3method(print,mev_egp_thselect)
5456
S3method(print,mev_gev)
5557
S3method(print,mev_gpd)
5658
S3method(print,mev_gpdbayes)
@@ -265,6 +267,7 @@ export(test.scoreindep)
265267
export(thselect.alrs)
266268
export(thselect.bab)
267269
export(thselect.cv)
270+
export(thselect.egp)
268271
export(thselect.expgqt)
269272
export(thselect.gbw)
270273
export(thselect.ksmd)

NEWS.md

Lines changed: 70 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,16 @@
1-
# mev 2.0
1+
# mev 2.1
2+
3+
## New:
4+
5+
- Function `thselect.egp` for threshold selection with tests similar to Northop and Coleman routine
6+
7+
## Changes:
8+
9+
- Arguments `method` for `tstab.egp` and `tstab.gp` now has `"lrt"` instead of `"profile"` (choice backward compatible).
10+
11+
# mev 2.0 (Release date 2025-10-22)
12+
13+
Major release with breaking changes (mostly function names and arguments) for more coherence. Many functions now flagged as deprecated, but changes to the syntax are often backward compatible.
214

315
## New:
416

@@ -103,17 +115,17 @@
103115

104116
## Changes
105117

106-
* Functions W.diag and NC.diag now have S3 plot and print methods
107-
* Changes to arguments (backward compatible) to xdat throughout
118+
* Functions `W.diag` and `NC.diag` now have S3 plot and print methods
119+
* Changes to arguments (backward compatible) to `xdat` throughout
108120
* Many dependencies used by single functions are now listed in Suggest.
109121

110122
## Fixes:
111123

112124
* `ext.coef` correctly handles arrays with missing values (reported by M. Jousset)
113125
* Optimization method in `fit.gev` now uses the PWM solution of Hosking (1985) as starting value
114-
* `gepll` now returns confidence intervals for param = "quant" (reported by D. Dupuis)
126+
* `gev.pll` now returns confidence intervals for `param = "quant"` (reported by D. Dupuis)
115127
* Fixes to NHPP order statistics density (returns -Inf outside of domain, also correctly evaluate for boundary case when xi=-1)
116-
* Optimization routines `fit.pp`, `fit.gev` and `fit.rlarg` now return correct MLE when solution lies on boundary (xi=-1) and are more robust to failure (gradients for nlminb return large values rather than NAs which caused the algorithm to stop).
128+
* Optimization routines `fit.pp`, `fit.gev` and `fit.rlarg` now return correct MLE when solution lies on boundary (xi=-1) and are more robust to failure (gradients for `nlminb` return large values rather than `NA` which caused the algorithm to stop).
117129
* Grimshaw's algorithm sometimes returned incorrect value because of too low tolerance for eta near zero. Set back to default settings.
118130
* `fit.gpd(..., method = "obre")` now returns additional failure messages if the algorithm drifts towards infeasible values.
119131
* `rparp` now correctly handles xi=0
@@ -126,84 +138,84 @@
126138

127139
## Fixes:
128140

129-
* rlarg.infomat incorrect sign for expected information for d=1
130-
* rmev function did not work for `alog` and `aneglog` (reported by Michael Lalancette)
141+
* `rlarg.infomat` incorrect sign for expected information for d=1
142+
* `rmev` function did not work properly for `alog` and `aneglog` (reported by Michael Lalancette)
131143
* Remove class()!= "matrix due to changes in R 4.0.0
132-
* egp.retlev now returns invisible object (new ordering and format).
144+
* `egp.retlev` now returns invisible object (new ordering and format).
133145

134146
## Changes:
135147

136-
* New S3 methods for objects returned by "fit" routines, for use in "lax" package
148+
* New S3 methods for objects returned by "fit" routines, for use in `lax` package
137149

138150
# mev 1.12 (Release date: 2019-06-24)
139151

140152

141153
## New:
142154

143-
* Function 'taildep' is multivariate equivalent to 'evd::chiplot'
144-
* Function 'rparpcs' for simulating from elliptical Pareto processes associated with max
145-
* 'rgparp' for simulation of generalized R Pareto processes
155+
* Function `taildep` is multivariate equivalent to `evd::chiplot`
156+
* Function `rparpcs` for simulating from elliptical Pareto processes associated with max
157+
* `rgparp` for simulation of generalized R Pareto processes
146158
* Exponent measure for Brown-Resnick and extremal Student model
147-
* 'spunif' for semi-parametric transform to uniform (tail modelled using GP)
148-
* 'rparp' now has attributes to give acceptance rate of accept/reject procedure.
149-
* Exponent measure estimators 'extcoef'
159+
* `spunif` for semi-parametric transform to uniform (tail modelled using GP)
160+
* `rparp` now has attributes to give acceptance rate of accept/reject procedure.
161+
* Exponent measure estimators `extcoef`
150162
* New method for robust OBRE estimates of GP parameters
151-
* Functions 'fit.gev','fit.gpd', 'fit.rlarg' and 'fit.pp' for maximum likelihood estimation
152-
* Default printing and plot optims (p-p and q-q plots) for mev_ objects
153-
* Changes to optimization routine for pp in 'W.diag' function, use of expected information matrix, change to default tuning parameter
154-
* New datasets: eskrain, maiquetia, nidd, venice, w1500m
163+
* Functions `fit.gev`, `fit.gpd`, `fit.rlarg` and `fit.pp` for maximum likelihood estimation
164+
* Default printing and plot optims (p-p and q-q plots) for `mev_` objects
165+
* Changes to optimization routine for pp in `W.diag` function, use of expected information matrix, change to default tuning parameter
166+
* New datasets: `eskrain`, `maiquetia`, `nidd`, `venice`, `w1500m`
155167

156168
## Fixes:
157169

158170
* Scaling of Brown-Resnick is now consistent with literature (half of semivariogram)
159-
* Degrees of freedom argument in C++ code for 'rmev' with extremal Student family was incorrect
160-
* 'rparp' now has a hard bound to ensure the vector of simulated vectors fits in memory.
171+
* Degrees of freedom argument in C++ code for `rmev` with extremal Student family was incorrect
172+
* `rparp` now has a hard bound to ensure the vector of simulated vectors fits in memory.
161173
* Change to Grimshaw routine to ensure shape not less than -1, constrained optimization method
162174
* Information matrix, score for GEV now interpolated in a neighborhood of zero to preserve continuity and avoid numerical overflow.
163175
* Information matrix of GEV: scale factor off. All scores and information matrix have been checked and limits as xi -> 0 implemented.
164-
* ext.index number of exceedances off by one, causing Inf in weight vector for lm (thanks to @MCristinaMiranda). Warnings now silenced by default.
176+
* `ext.index`: number of exceedances off by one, causing `Inf` in weight vector for `lm` (thanks to @MCristinaMiranda). Warnings now silenced by default.
165177

166178
## Changes:
167179

168-
* coordinates for rmev, rparp, etc. now use `coord` instead of `loc` to avoid confusion with location parameter in `rgparp`
169-
* Removed dependency to 'ismev', 'rootsolve' (replaced with 'nleqslv' routine) and 'numDeriv'.
180+
* coordinates for `rmev`, `rparp`, etc. now use `coord` instead of `loc` to avoid confusion with location parameter in `rgparp`
181+
* Removed dependency to `ismev`, `rootsolve` (replaced with `nleqslv` routine) and `numDeriv`.
170182
* Change to plot for profile log-likelihood methods
171-
* 'smith.penult' function has new arguments (backward compatible). The quantiles 'u' are now returned for Smith penultimate approximations with 'method = "pot"'
183+
* `smith.penult` function has new arguments (backward compatible). The quantiles `'u'` are now returned for Smith penultimate approximations with `method = "pot"`
172184

173185

174186
# mev 1.11 (Release date: 2018-02-23)
175187

176188

177189
## New:
178190

179-
* Function 'rparp' for simulation from R-Pareto Processes via rejection sampling
180-
* Function 'gepll' and 'gpd.pll' for penalized profile likelihood and tangent exponential model approximations
181-
* New functions 'chibar', 'angextrapo' and 'lambdadep' for bivariate and multivariate model estimation, based on work of Tawn et al.
191+
* Function `rparp` for simulation from R-Pareto Processes via rejection sampling
192+
* Function `gev.pll` and `gpd.pll` for penalized profile likelihood and tangent exponential model approximations
193+
* New functions `chibar`, `angextrapo` and `lambdadep` for bivariate and multivariate model estimation, based on work of Tawn et al.
182194
* Dirichlet mixture smoothing for empirical angular distribution of de Carvalho et al. (2013)
183-
* Functions 'gemle' and 'gpd.mle' for maximum likelihood estimates of transformed parameters
184-
* Functions 'geabias' and 'gpd.abias' for asymptotic bias of block maxima for fixed sample sizes or fixed thresholds
195+
* Functions `gev.mle` and `gpd.mle` for maximum likelihood estimates of transformed parameters
196+
* Functions `gev.abias` and `gpd.abias` for asymptotic bias of block maxima for fixed sample sizes or fixed thresholds
185197

186198
## Changes:
187199

188-
* Functions 'rmev', 'rmevspec', etc. now only accept variogram functions 'vario' that have distance as argument
189-
* Simulation from 'rmev' and 'rmevspec' faster to refactoring of code
190-
* Function 'smith.penult' now has a 'family' as argument for specifying distributions via a string
191-
* Function 'getem' and 'gpd.tem' are now a wrapper for 'gepll' and 'gpd.pll', respectively. Routine should be more robust
200+
* Functions `rmev`, `rmevspec`, etc. now only accept variogram functions `vario` that have distance as argument
201+
* Simulation from `rmev` and `rmevspec` now faster due to refactoring of code
202+
* Function `smith.penult` now has a 'family' as argument for specifying distributions via a string
203+
* Function `gev.tem` and `gpd.tem` are now wrappers for `gev.pll` and `gpd.pll`, respectively. Routine should be more robust
192204
* TEM corrections now handle more options
193205
* Clarifications in the vignette about the asymmetric negative logistic model (thanks to A. Stephenson)
194206

195207
## Fixes:
196208

197-
* Fixed incorrect scaling in 'infomat.test' (thanks to P. Northrop)
198-
* Model "br" now simulates from stationary version only if argument 'sigma' is provided, and otherwise samples intrinsically Gaussian processes
199-
* Display of p-value matrix for 'infomat.test'
209+
* Fixed incorrect scaling in `infomat.test` (thanks to P. Northrop)
210+
* Model `"br"` now simulates from stationary version only if argument `'sigma'` is provided, and otherwise samples intrinsically Gaussian processes
211+
* Display of p-value matrix for `infomat.test`
200212

201213
# mev 1.10 (Release date: 2017-02-01)
202214

203215

204216
## New:
205217

206-
* Added 'negdir' model to `rmev`
218+
* Added `'negdir'` model to `rmev` families
207219
* Changes to `angmeas` to include different weighting if the region of interest is 'max' or 'min'
208220

209221
## Fixes:
@@ -212,7 +224,7 @@
212224

213225
## Changes:
214226

215-
* Fixed argument matching in function 'egp2'
227+
* Fixed argument matching in function `fit.egp` with model `egp2`
216228

217229

218230

@@ -226,34 +238,34 @@
226238

227239
## Changes:
228240

229-
* model "br" is now distinct from "hr"
241+
* `rmev`, etc.: model `"br"` is now distinct from `"hr"`
230242

231243
## Fixes:
232244

233245
* fixed invalid random number generation from logistic model for near-independence cases
234246

235247

236-
# mev v1.7 (Release date: 2016-06-07)
248+
# mev 1.7 (Release date: 2016-06-07)
237249

238250

239251
## New:
240252

241-
* ext.index Extremal index estimates based on interexceedance and gap times
242-
* infomat.test Information matrix test of Suveges and Davison (2010)
253+
* `ext.index` Extremal index estimates based on interexceedance and gap times
254+
* `infomat.test` Information matrix test of Suveges and Davison (2010)
243255

244256
## Fixes:
245257

246258
* fixed an error in the acceptance rate for the `gp.fit` MCMC
247259

248260

249-
# mev v1.6.1 (Release date: 2016-03-15)
261+
# mev 1.6.1 (Release date: 2016-03-15)
250262

251263

252264
## Fixes:
253265

254266
* fixed an error in the normal sampler (affecting version 1.5 and 1.6). All simulations of Brown-Resnick or extremal-Student were affected by the mistake
255267

256-
# mev v1.6 (Release date: 2016-03-08)
268+
# mev 1.6 (Release date: 2016-03-08)
257269

258270

259271
## New:
@@ -264,7 +276,7 @@
264276

265277
* `gp.fit` ample changes to the function, in particular a fix for the printing method, handling of errors and inclusion of the Zhang (2010) method and MCMC algorithm for the latter. This function is still preliminary and may updated in the nearby future to include further possibilities.
266278

267-
# mev v1.5 (Release date: 2016-02-16)
279+
# mev 1.5 (Release date: 2016-02-16)
268280

269281

270282
## New:
@@ -278,34 +290,35 @@
278290

279291
## Changes:
280292

281-
* check for marginal mean constraint for the Dirichlet mixture now has tolerance
293+
* Check for marginal mean constraint for the Dirichlet mixture now has tolerance
282294

283-
# mev v1.3 (Release date: 2015-10-05)
295+
# mev 1.3 (Release date: 2015-10-05)
284296

285297

286298
## Changes:
287299

288-
* Extremal Dirichlet model now implemented with "ef"
289-
* Added Smith and asymmetric (negative) logistic model (differs from bivariate setting for aneglog, given that the later is not a valid DF according to Stephenson).
290-
* rmev can now return arrays for random fields on regular grids ("hr","exstud" and "smith" models).
300+
* Extremal Dirichlet model now implemented with `"ef"`
301+
* Added Smith and asymmetric (negative) logistic model (differs from bivariate setting for `aneglog`, given that the later is not a valid DF according to Stephenson).
302+
* `rmev` can now return arrays for random fields on regular grids (`"hr"`,`"exstud"` and `"smith"` models).
291303

292304

293305

294-
# mev v1.2 (Release date: 2015-08-23)
306+
# mev 1.2 (Release date: 2015-08-23)
295307

296308

297309
## Changes:
298310

299311
* Added the negative bilogistic and the scaled Dirichlet models.
300-
* Extremal Dirichlet model implemented with "sm" only.
312+
* Extremal Dirichlet model implemented with `"sm"` only.
301313

302-
# mev v1.1 (Release date: 2015-08-19)
314+
# mev 1.1 (Release date: 2015-08-19)
303315

304316

305317
## Changes:
306318

307-
* Implementation of sampler from spectral distribution, moving rdirspec and rbilogspec to background along with other functions.
308-
* Fixed a typo in rPextstud setting arguments of newly created arma vector to zero
319+
* Implementation of sampler from spectral distribution, moving `rdirspec` and `rbilogspec` to internal functions along with other functions.
320+
* Fixed a typo in `rPextstud` setting arguments of newly created arma vector to zero
309321

310-
mev v1.0 (Release date: 2014-08-16)
322+
# mev 1.0 (Release date: 2014-08-16)
311323

324+
Initial submission

R/condextr.R

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,5 +581,9 @@ fit.condex <- function(
581581

582582
# TODO simulate from conditional extremes model above
583583

584-
584+
# pspgp <- function(x){
585+
# spunif(x, thresh = thresh
586+
#
587+
# ecdf(x) + pgpd()
588+
# }
585589
# predict method with importance sampling and algorithm from paper

0 commit comments

Comments
 (0)