Description Usage Arguments Value Examples
Maximum likelihood for generaluzed extreme value and generalized Pareto, using modified Newton-Raphson
1 2 3 4 5 6 7 8 9 |
xdata |
data set, should be positive-valued exceedances for gpmle |
maxitn |
maximum number of iterations for Newton-Raphson method |
x |
scalar of vector |
p |
scalar of vector, values in 0 to 1 |
xi |
tail index or shape parameter of GEV |
mu |
location parameter |
sigma |
scale parameter |
list with $loglik, $params, $covar for gevmle and gpmle functions
density, cdf, quantile or log density values with the other functions
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | set.seed(123)
x=rnorm(2000)
xmat=matrix(x,40,50)
mxdat=apply(xmat,1,max)
gevmle(mxdat) # xi is negative because of sub-asymptotics
gpmle(x[x>1.3]-1.3)
rpareto=function(n,alp,s)
{ u=runif(n); tem=u^(-1/alp)-1; return(s*tem) }
set.seed(123)
x=rpareto(2000,alp=3,s=1)
xmat=matrix(x,40,50)
mxdat=apply(xmat,1,max)
gevmle(mxdat) # xi close to 1/alp=1/3
gpmle(x[x>1.2]-1.2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.