csc.C3.test {pEPA}R Documentation

Computes Test for Cross-Sectional Clusters.

Description

This function computes test of the equal predictive accuracy for cross-sectional clusters. It corresponds to C^{(3)}_{nT} statistic in the referenced paper by Akgun et al. (2024). The null hypothesis of this test is that a pair of forecasts have the same expected accuracy among cross-sectional clusters. However, their predictive accuracy can be different across the clusters, but the same among each cluster. The test allows for strong cross-sectional dependence.

Usage

csc.C3.test(evaluated1,evaluated2,realized,loss.type="SE",cl)

Arguments

evaluated1

same as in pool_av.test, but cross-sections are ordered rowwise

evaluated2

same as in pool_av.test, but cross-sections are ordered rowwise

realized

same as in pool_av.test, but cross-sections are ordered rowwise

loss.type

same as in pool_av.test

cl

vector of the beginning indices of rows for each pre-defined clusters – as a result always cl[1]=1

Value

class htest object, list of

statistic

test statistic

parameter

K, number of cross-sectional clusters

alternative

alternative hypothesis of the test

p.value

p-value

method

name of the test

data.name

names of the tested data

References

Akgun, O., Pirotte, A., Urga, G., Yang, Z. 2024. Equal predictive ability tests based on panel data with applications to OECD and IMF forecasts. International Journal of Forecasting 40, 202–228.

See Also

pool_av.test, csc.C1.test

Examples


data(forecasts)
y <- t(observed)
# just to reduce computation time restrict to energy commodities only
y <- y[1:8,]
f.bsr <- matrix(NA,ncol=ncol(y),nrow=8)
f.dma <- f.bsr
# extract prices predicted by BSR rec and DMA methods
for (i in 1:8)
  {
    f.bsr[i,] <- predicted[[i]][,1]
    f.dma[i,] <- predicted[[i]][,9]
  }
# 2 cross-sectional clusters: crude oil and other energy commodities
cs.cl <- c(1,4)
t <- csc.C3.test(evaluated1=f.bsr,evaluated2=f.dma,realized=y,loss.type="SE",cl=cs.cl)


[Package pEPA version 1.0 Index]