# \donttest{
# Generate some locations
set.seed(1)
lat <- lon <- seq(from=-5, to=5, length=20)
sites <- as.matrix(expand.grid(lat,lon))
# Example using the extremal-t
set.seed(2)
z <- rExtDepSpat(1, sites, model="ET", cov.mod="powexp", DoF=1,
nugget=0, range=3, smooth=1.5,
control=list(method="exact"))
fields::image.plot(lat, lon, matrix(z$vals,ncol=20) )
# Example using the extremal skew-t
set.seed(3)
z2 <- rExtDepSpat(1, sites, model="EST", cov.mod="powexp", DoF=5,
nugget=0, range=3, smooth=1.5, alpha=c(0,5,5),
acov1=sites[,1], acov2=sites[,2],
control=list(method="exact"))
fields::image.plot(lat, lon, matrix(z2$vals,ncol=20) )
# }
Run the code above in your browser using DataLab