gev.d.nll.Rd 1.09 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/gevdfit.R
\name{gev.d.nll}
\alias{gev.d.nll}
\title{computes negative log-likelihood of d-gev model}
\usage{
gev.d.nll(xdat, ds, mut, sig0, xi, theta, eta)
}
\arguments{
\item{xdat}{numeric vector containing observations}

12
\item{ds}{numeric vector containing coresponding durations (1/60 corresponds to 1 minute, 1 corresponds to 1 hour)}
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31

\item{mut, sig0, xi, theta, eta}{numeric vectors containing corresponding mles for each of the parameters}
}
\value{
single value containing negative log likelihood
}
\description{
computes negative log-likelihood of d-gev model
}
\examples{
# compute nll of values not included in fit
train.set <- example[example$d!=2,]
test.set <- example[example$d==2,]
fit <- gev.d.fit(train.set$dat,train.set$d,mul = c(1,2),sigl = 1
          ,ydat = as.matrix(train.set[c('cov1','cov2')]))
params <- gev.d.params(fit,ydat = as.matrix(test.set[c('cov1','cov2')]))
gev.d.nll(xdat = test.set$dat,ds = test.set$d,mut = params[,1],sig0 = params[,2],xi = params[,3]
          ,theta = params[,4],eta = params[,5])
}