Learn R Programming

covatest (version 1.0.1)

sepindex-class: Class "sepindex"

Description

A class for the non-separability index (r) for different spatial and temporal lags: $$r(h, u, \Theta)= \rho(h, u;\Theta)/ [\rho(h,0;\Theta)\rho(0,u;\Theta)]$$ with \(\rho(h, u;\Theta)>0\); \(\rho(h,0;\Theta)>0\) and \(\rho(0,u;\Theta)>0\). On the basis of this index, the type of non-separability of the covariance function can be analyzed.

Usage

sepindex(vario_st, nt, ns, globalSill)

# S4 method for sepindex boxplot(x, ...)

# S4 method for sepindex show(object)

# S4 method for sepindex [(x, i, j)

# S4 method for sepindex summary(object)

Arguments

vario_st

spatio-temporal sample variogram, output from variogramST

nt

integer, the number of temporal lags in vario_st

ns

integer, the number of spatial lags in vario_st

globalSill

numeric, the value of the sample variance

x

object of class sepindex for methods boxplot and extract

...

any arguments that will be passed to the panel plotting functions

object

object of class sepindex for methods show and summary

i

index specifing elements to extract. Each row includes data for specific spatio-temporal lags

j

index specifing elements to extract. Set 1 for spatial lags (hs), 2 for temporal lags (ht) and 3 for the non-separability index (SepIndex)

Slots

sep.index.ratio

the empirical non-separability index ratio and the corresponding spatio-temporal lags

cov.st

the spatio-temporal sample covariance function and the corresponding spatio-temporal lags

cov.tm

the purely temporal sample covariance function and the corresponding temporal lags

cov.sp

the purely spatial sample covariance function and the corresponding spatial lags

References

De Iaco, S., Posa, D., 2013, Positive and negative non-separability for space-time covariance models. Journal of Statistical Planning and Inference, 143 378--391.

Pebesma, E., 2004, Multivariable geostatistics in S: the gstat package. Computers & Geosciences, 30 683--691.

Rodriguez, A., Diggle, P.J., 2010, A class of convolution-based models for spatio-temporal processes with non-separable covariance structure. Scandinavian Journal of Statistics, 37(4) 553--567.

See Also

variogramST

Examples

Run this code
# NOT RUN {
# --start define the STFDF rr_13-- #
library(sp)
library(spacetime)
library(gstat)
data(air)
ls()
if (!exists("rural")) rural = STFDF(stations, dates, data.frame(PM10 =
as.vector(air)))
rr = rural[,"2005::2010"]
unsel = which(apply(as(rr, "xts"), 2, function(x) all(is.na(x))))
r5to10 = rr[-unsel,]
rr_13 <- r5to10[c("DEHE046","DESN049","DETH026","DENW063","DETH061","DEBY047",
"DENW065","DEUB029","DENW068","DENI019","DEHE051","DERP016","DENI051"),
"2005::2006"]
# --end define the STFDF rr_13-- #

#compute the Global Sill
C00_13<-var(rr_13[,,"PM10"]@data[[1]], na.rm = TRUE)

#estimate the spatio-temporal variogram
data(vv_13)
nonsep.index<-sepindex(vario_st = vv_13, nt = 16, ns = 4, globalSill = C00_13)

##methods for sepindex

#1. show
nonsep.index

#2. summary
summary(nonsep.index)

#3. boxplot
boxplot(nonsep.index, ylab="Non-separability ratio")

#4. [ extract
nonsep.index[1:8, ] #selection of the first 8 rows
nonsep.index[1:8, 1:2] #selection of the first 2 columns
# }

Run the code above in your browser using DataLab