predict.spatgev(SpatialExtremes)
predict.spatgev()所属R语言包:SpatialExtremes
Prediction of the GEV parameters
的GEV参数预测的
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This function predicts the marginal GEV parameters from a fitted ”spatial GEV” model.
此功能预测的边际GEV参数从一个装有“空间GEV”的模式。
用法----------Usage----------
## S3 method for class 'spatgev'
predict(object, newdata, ret.per = NULL, ...)
参数----------Arguments----------
参数:object
An object of class spatgev”. Most often, it will be the output of the function fitspatgev.
一个对象的类spatgev的“。大多数情况下,这将是功能fitspatgev的输出。
参数:newdata
An optional data frame in which to look for variables with which to predict. If omitted, the fitted values are used.
一个可选的数据框中寻找变量,用以预测。如果省略该参数,拟合值。
参数:ret.per
Numeric vector giving the return periods for which return levels are computed. If NULL (default), no return levels are computed.
为重现期的收益水平计算的数字矢量。如果NULL(默认),没有回报水平计算。
参数:...
further arguments passed to or from other methods.
进一步的参数传递给其他方法。
值----------Value----------
'predict.spatgev' produces a vector of predictions or a matrix of predictions.
predict.spatgev产生一个预测的矢量或矩阵的预测。
(作者)----------Author(s)----------
Mathieu Ribatet
参见----------See Also----------
predict
predict
实例----------Examples----------
## 1- Simulate a max-stable random field[#1 - 模拟一个最大稳定的随机场]
n.site <- 35
locations <- matrix(runif(2*n.site, 0, 10), ncol = 2)
colnames(locations) <- c("lon", "lat")
data <- rmaxstab(50, locations, cov.mod = "whitmat", nugget = 0, range = 3,
smooth = 0.5)
## 2- Transformation to non unit Frechet margins[#2 - 非单位的Frechet空间的转换]
param.loc <- -10 + 2 * locations[,2]
param.scale <- 5 + 2 * locations[,1]
param.shape <- rep(0.2, n.site)
for (i in 1:n.site)
data[,i] <- frech2gev(data[,i], param.loc[i], param.scale[i],
param.shape[i])
## 3- Fit a ''spatial GEV'' mdoel to data with the following models for[#3 - 装上一个“空的GEV”mdoel到以下车型]
## the GEV parameters[#GEV参数]
form.loc <- loc ~ lat
form.scale <- scale ~ lon
form.shape <- shape ~ 1
fitted <- fitspatgev(data, locations, form.loc, form.scale, form.shape)
## 4- GEV parameters estimates at each locations or at ungauged locations[#4 - GEV参数估计在每一个地方,或在无资料区域]
predict(fitted)
ungauged <- data.frame(lon = runif(10, 0, 10), lat = runif(10, 0, 10))
predict(fitted, ungauged)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|