multipleVLGrangerFunc {VLTimeCausality} | R Documentation |
multipleVLGrangerFunc
Description
multipleVLGrangerFunc is a function that infers Variable-lag Granger Causality of all pairwises of m
time series TS[,1],...TS[,m]
.
Usage
multipleVLGrangerFunc(
TS,
maxLag,
alpha = 0.05,
gamma = 0.3,
autoLagflag = TRUE,
causalFlag = 0,
VLflag = TRUE,
family = gaussian
)
Arguments
TS |
is a numerical time series of effect where |
maxLag |
is a maximum possible time delay. The default is 0.2*length(Y). |
alpha |
is a significance level of F-test to determine whether |
gamma |
is a parameter to determine whether |
autoLagflag |
is a flag for enabling the automatic lag inference function. The default is true. If it is set to be true, then maxLag is set automatically using cross-correlation. Otherwise, if it is set to be false, then the function takes the maxLag value to infer Granger causality. |
causalFlag |
is a choice of criterion for inferring causality:
|
VLflag |
is a flag of Granger causality choice: either |
family |
is a parameter of family of function for Generalized Linear Models function (glm). The default is |
Value
This function returns of a list of an adjacency matrix of causality where adjMat[i,j]
is true if TS[,i]
causes TS[,j]
.
Examples
## Generate simulation data
#TS <- MultipleSimulationVLtimeseries()
## Run the function
#out<-multipleVLGrangerFunc(TS)