mathnet / mathnet-numerics

Math.NET Numerics
http://numerics.mathdotnet.com
MIT License
3.48k stars 895 forks source link

Johansen Cointegration Test #141

Closed cdrnet closed 3 years ago

cdrnet commented 10 years ago

From: https://mathnetnumerics.codeplex.com/workitem/5730

Would like to see support for Johansen test.

http://www.mathworks.com/help/econ/jcitest.html http://en.wikipedia.org/wiki/Johansen_test

jaredbroad commented 9 years ago

Bump. Any plans @cdrnet? @mchandschuh

cdrnet commented 9 years ago

How would an API design for this ideally look like, that would support your use case in a clean way?

mchandschuh commented 9 years ago

Ideally the API would support usage similar to this python implementation.

Following along the lines of the Correlation class, I could see something like the following in C#:

var result = Cointegration.Johansen(Matrix<double> matrix, int order, int laggedDifferences);
glyphard commented 9 years ago

This suggested API makes sense.

FWIW, the suggested api is reasonably consistent with the R package for Johansen Cointegration Test (urca). It is a little bit different than the matlab econometrics toolbox version of Johansen Cointegration, but that is probably ok because the matlab api is older and offers a lot more complex control over the implementation details which likely wouldn't be built into a first version of JCI in mathnet.

On Fri, Sep 18, 2015 at 2:30 AM, Michael notifications@github.com wrote:

Ideally the API would support usage similar to this python https://github.com/josef-pkt/statsmodels/blob/coint/statsmodels/tsa/johansen.py implementation.

Following along the lines of the Correlation class, I could see something like the following in C#:

var result = Cointegration.Johansen(Matrix matrix, int order, int laggedDifferences);

— Reply to this email directly or view it on GitHub https://github.com/mathnet/mathnet-numerics/issues/141#issuecomment-141356712 .

Levitikon217 commented 7 years ago

Any updates on this? It would be really cool if any Cointegration support was added. Johansen or Augmented Dickey Fuller (ADF)!