X hits on this document

44 views

0 shares

0 downloads

0 comments

5 / 12

##EXERCISE 1: Bayesian Estimation of covariance parameters

##EXERCISE 2: Moving neighborhood  kriging

##EXERCISE 3: ANISTROPY

##EXERCISE 4: Maps and Images

########################################################################

# download your data using read.table

# to learn more about read.table  type

# > ? read.table

coal.ash<-read.table('coalash.txt')

coal.m<-as.matrix(coal.ash)

davis.txt<-read.table('davis.txt')

davis.m<-as.matrix(davis.txt)

###################################

##EXERCISE 1: Estimating model parameters

###A. Bayesian estimates of model parameters:

#Function:   krige.bayes

# You obtain posteriors for the trend, range, partial  sill and nugget

# Recommended (default) priors:

# uniform for beta, 1/sigma^2 for the partial  sill

# and discrete uniform for the range  and nugget.

#

# aniso.pars are the parameters for anisotropy: stretching and rotation angle.

#

# the default is with nugget 0, but you

# can also get a posterior for the nugget when you give a prior to the nugget,

# by saying nugget.prior="uniform"

#

#Additional information:

#----------------------

# This function computes (Bayesian) estimates of a spatial linear

#model and performs Bayesian and/or kriging prediction in a set of

#locations specified by the user.

# Priors options for mean and/or covariance parameters

# coords       : data coordinates (vector for 1d or matrix for 2d data)

#  data         : vector with data values

# locations    : coordinates of points to be estimated (vector for 1d or

# matrix for 2d data). If locations='no' only model parameters estimates are

#returned if the full bayesian model is considered.

# trend.d      : trend data in data locations. Default is constant trend.

#The options '1st' or '2nd' builts a first or second degree polinomial.

# trend.l      : trend data in locations to be estimated. Default

#is constant trend. The options '1st' or '2nd' builts a first or second

#degree polinomial.

Document info
Document views44
Page views48
Page last viewedWed Dec 07 18:30:29 UTC 2016
Pages12
Paragraphs458
Words1924

Comments