crosscor_2series {IndGenErrors}R Documentation

Cross-correlations for testing independence between the innovations of 2 series of same length

Description

This function computes the cross-correlations between x(t) and y(t-l), for l=-lag,.., lag, and also the combination (Wald's type) of these statistics.

Usage

crosscor_2series(x, y, lag, graph = TRUE)

Arguments

x

Pseudo-observations (or residuals) of first series

y

Pseudo-observations (or residuals) of second series

lag

Maximum number of lags around 0

graph

Set to TRUE for a correlogram for all possible lags.

Value

stat

Cross-correlations for all lags

LB

Sum of squares of cross-correlations

pvalue

P-value of LB

subsets

c(-lag:lag)

n

length of the time series

References

Duchesne, Ghoudi & Remillard (2012). On Testing for independence between the innovations of several time series. CJS, vol. 40, 447-479.

Examples

data(gas)
outr <-crosscor_2series(gas$xres,gas$yres,3)


[Package IndGenErrors version 0.1.4 Index]