R: Generalized Extreme Value Distribution (for maxima)
GEV
R Documentation
Generalized Extreme Value Distribution (for maxima)
Description
Density, distribution function, quantile function and random generation for the generalized extreme value distribution (for maxima) with shape, scale, and location parameters equal to shape, scale, and location, respectively.
logical; if TRUE, probabilities p are given as log(p).
lower.tail
logical; if TRUE (default), probabilities are P[X <= x],otherwise, P[X > x].
Details
If X is a random variable distributed according to a generalized extreme value distribution, it has density
f(x) = 1/scale*(1+shape*((x-location)/scale))^(-1/shape-1)*exp(-(1+shape*((x-location)/scale))^(-1/shape))
Value
dgev gives the density, pgev gives the distribution function, qgev gives the quantile function, and rgev generates random deviates.
References
Coles, S. (2001) An introduction to statistical modeling of extreme values. Springer
Examples
x <- rgev(1000,-.1,3,100)
hist(x,freq=FALSE,col='gray',border='white')
curve(dgev(x,-.1,3,100),add=TRUE,col='red4',lwd=2)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(FAdist)
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/FAdist/GEV.Rd_%03d_medium.png", width=480, height=480)
> ### Name: GEV
> ### Title: Generalized Extreme Value Distribution (for maxima)
> ### Aliases: dgev pgev qgev rgev
> ### Keywords: distribution
>
> ### ** Examples
>
> x <- rgev(1000,-.1,3,100)
> hist(x,freq=FALSE,col='gray',border='white')
> curve(dgev(x,-.1,3,100),add=TRUE,col='red4',lwd=2)
>
>
>
>
>
> dev.off()
null device
1
>