Partial Directed Coherence

AsymptoticPDC.pdcFunction
pdc([model], u; nFreqs::Int = 128, α = 0.0, fs = 1, metric::String="euc", maxorder::Int=30, criterion::Union{Nothing,String}="AIC", method::String="NS", verbose::Bool=true)

Computes the partial directed coherence pdc based on a multivariate AR model of the input matrix u containing the signals/channels xi, u = [x1 x2 ... xn]. If you already fitted a model just put it as first parameter to avoid recalculation.

Args

  • u: input Matrix containing signals 1 to n u = [x1 x2 ... xn]

Keywords

  • nFreqs = 128: number of frequencies for which the pdc shall be calculated
  • metric = "euc": If "euc" the basic pdc is returned, else if "diag" a generalized (normalized for different covariances) pdc is returned
  • fs = 1: sampling frequency in Hz
  • α = 0.0: significance level for asymptotic statistics. If 0 no statistics are computed which is faster

The following Keywords are inherited from mcar used for model estimation:

* maxorder::Union{Nothing, Int} = `nothing`: The maximal order of the AR model, defaults to `nothing` where the order is chosen based on a simple heuristic (maxorder = 3√samples/nChannels; Nuttall 1976)
* criterion = `"AIC"`: The information criterion used to choose the model order. Use one of the following:
    - `"AIC"`: Akaike's Informaion Criterion
    - `"HQ"`: Hannan Quinn
    - `"BIC"`: Bayesian Information Criterion, Schwarz 1978
    - `"FPE"`: Final prediction error, Akaike, 1970
    - nothing: maxorder becomes the fixed order
* method = `"LS"`: Method used for etsimation. Use one of:
    - `"LS"` least squares based on \ 
    - `"NS"` Nuttall-Strand Method (multi-channel generalization of the single-channel Burg lattice algorithm)
    - `"VM"` Vieira-Morf Method (multi-channel generalization of the single-channel geometric lattice algorithm)

Return

Returns an object that is a subtype of AbstractPartialDirectedCoherence depending on if asymptotic statistics have been calculated.

source