gev.d.fit.Rd 3.98 KB
 Jana Ulrich committed Nov 13, 2018 1 % Generated by roxygen2: do not edit by hand  2 % Please edit documentation in R/gevdfit.R  Jana Ulrich committed Nov 13, 2018 3 4 5 6 \name{gev.d.fit} \alias{gev.d.fit} \title{Maximum-likelihood Fitting of the duration dependent GEV Distribution} \usage{  Laura Mack committed Jul 30, 2020 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 gev.d.fit( xdat, ds, ydat = NULL, mul = NULL, sigl = NULL, shl = NULL, thetal = NULL, etal = NULL, mulink = make.link("identity"), siglink = make.link("identity"), shlink = make.link("identity"), thetalink = make.link("identity"), etalink = make.link("identity"), init.vals = NULL, theta_zero = FALSE, show = TRUE, method = "Nelder-Mead", maxit = 10000, ... )  Jana Ulrich committed Nov 13, 2018 28 29 } \arguments{  30 31 \item{xdat}{A vector containing maxima for different durations. This can be obtained from \code{\link{IDF.agg}}.}  Jana Ulrich committed Nov 13, 2018 32   Laura Mack committed Aug 20, 2020 33 34 \item{ds}{A vector of aggregation levels corresponding to the maxima in xdat. 1/60 corresponds to 1 minute, 1 corresponds to 1 hour.}  Jana Ulrich committed Nov 13, 2018 35   36 37 38 \item{ydat}{A matrix of covariates for generalized linear modelling of the parameters (or NULL (the default) for stationary fitting). The number of rows should be the same as the length of xdat.}  Jana Ulrich committed Nov 13, 2018 39 40  \item{mul, sigl, shl, thetal, etal}{Numeric vectors of integers, giving the columns of ydat that contain  41 covariates for generalized linear modelling of the parameters (or NULL (the default)  Jana Ulrich committed Nov 13, 2018 42 43 44 if the corresponding parameter is stationary). Parameters are: modified location, scale_0, shape, duration offset, duration exponent repectively.}  Jana Ulrich committed Sep 30, 2019 45 46 \item{mulink, siglink, shlink, thetalink, etalink}{Link functions for generalized linear modelling of the parameters, created with \code{\link{make.link}}.}  Jana Ulrich committed Nov 13, 2018 47   Laura Mack committed Jul 30, 2020 48 49 50 51 52 53 54 \item{init.vals}{vector of length 5, giving initial values for parameter intercepts used to model the parameters (order: mu, sigma, xi, theta, eta). If NULL (the default) is given, initial parameters are obtained internally by fitting the GEV separately for each duration and applying a linear model to obtain the duration dependency of the location and shape parameter.} \item{theta_zero}{Logical value, indicating if theta should be estimated (FALSE, the default) or should stay zero.}  Jana Ulrich committed Nov 13, 2018 55 56 57 58 59 60 61 62 63 64 65 66  \item{show}{Logical; if TRUE (the default), print details of the fit.} \item{method}{The optimization method used in \code{\link{optim}}.} \item{maxit}{The maximum number of iterations.} \item{...}{Other control parameters for the optimization.} } \value{ A list containing the following components. A subset of these components are printed after the fit.  Laura Mack committed Jul 30, 2020 67 If \code{show} is TRUE, then assuming that successful convergence is indicated,  68 the components nllh, mle and se are always printed.  Jana Ulrich committed Sep 30, 2019 69 \item{nllh}{single numeric giving the negative log-likelihood value}  Jana Ulrich committed Nov 13, 2018 70 71 \item{mle}{numeric vector giving the MLE's for the modified location, scale_0, shape, duration offset and duration exponent, resp.}  Jana Ulrich committed Sep 30, 2019 72 \item{se}{numeric vector giving the standard errors for the MLE's (in the same order)}  Laura Mack committed Jul 30, 2020 73 \item{trans}{A logical indicator for a non-stationary fit.}  Jana Ulrich committed Nov 13, 2018 74 75 76 77 \item{model}{A list with components mul, sigl, shl, thetal and etal.} \item{link}{A character vector giving inverse link functions.} \item{conv}{The convergence code, taken from the list returned by \code{\link{optim}}. A zero indicates successful convergence.}  Laura Mack committed Jul 30, 2020 78 \item{data}{data is standardized to standard Gumbel.}  79 80 81 82 \item{cov}{The covariance matrix.} \item{vals}{Parameter values for every data point.} \item{init.vals}{Initial values that where used.} \item{ds}{Durations for every data point.}  Jana Ulrich committed Nov 13, 2018 83 84 } \description{  85 86 Modified \code{\link[ismev]{gev.fit}} function for Maximum-likelihood fitting for the duration dependent generalized extreme  Laura Mack committed Jul 30, 2020 87 value distribution, following Koutsoyiannis et al. (1998), including generalized linear  88 modelling of each parameter.  Jana Ulrich committed Nov 13, 2018 89 }  Jana Ulrich committed Feb 05, 2019 90 91 92 93 94 95 96 97 98 99 100 101 102 103 \examples{ # sampled random data from d-gev with covariates # GEV parameters: # mu = 4 + 0.2*cov1 +0.5*cov2 # sigma = 2+0.5*cov1 # xi = 0.5 # theta = 0 # eta = 0.5 data('example',package ='IDF') gev.d.fit(xdat=example$dat,ds = example$d,ydat=as.matrix(example[,c('cov1','cov2')]) ,mul=c(1,2),sigl=1) }  Jana Ulrich committed Nov 13, 2018 104 \seealso{  105 \code{\link{dgev.d}}, \code{\link{IDF.agg}}, \code{\link{gev.fit}}, \code{\link{optim}}  Jana Ulrich committed Nov 13, 2018 106 }