Results 1 to 12 of 12
  1. #1
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default Autocorrelation function (same with matlab) is needed !!

    Hey there,

    I need an autocorrelation function that will take a serries and return as result the autocorrelation series of the signal just as matlab autocorr.m do.

    I Could do it in matlab but since my thesis project is in java i prefer a method of doing the same job with autocorr in matlab but in java.

    I try a lot of methods found around but i dont get the same results with the ones i get from matlab autocorr.

    If anyone has anything that can help please reply.

  2. #2
    masijade is offline Senior Member
    Join Date
    Jun 2008
    Posts
    2,571
    Rep Power
    8

    Default

    Write one?

    Another possibility (I don't know if this package has it but you can check it out) is the Colt package from CERN

  3. #3
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default

    hehe if it was clear to me how autocorrelation provide the results i would do it already but i dont know :)

    I already see the second solution but the autocorrelation method return a single value and that doesnt work with my problem!!

    Thanks a lot for reply

  4. #4
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,019
    Blog Entries
    7
    Rep Power
    20

    Default

    Quote Originally Posted by Pericles View Post
    hehe if it was clear to me how autocorrelation provide the results i would do it already but i dont know :)

    I already see the second solution but the autocorrelation method return a single value and that doesnt work with my problem!!

    Thanks a lot for reply
    Doesn't this link help? It's just a bit of array fiddling ...

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

  5. #5
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default

    This not what i want. This isn't the way the autocorr of matlab work!!

    Thanks for reply

  6. #6
    masijade is offline Senior Member
    Join Date
    Jun 2008
    Posts
    2,571
    Rep Power
    8

    Default

    Quote Originally Posted by Pericles View Post
    This not what i want. This isn't the way the autocorr of matlab work!!

    Thanks for reply
    So then how does it work?

  7. #7
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default

    Well i dont know ?

    But since the results (wiki solution and autocorr of matlab) are not the same this mean that are not the same :) right ?

    I try to see the .m file but since my matlab code knowledge isn't good i cant understand it!

    Thanks for the reply again !!!

  8. #8
    masijade is offline Senior Member
    Join Date
    Jun 2008
    Posts
    2,571
    Rep Power
    8

    Default

    Uhm, you do realise that the wiki shows two different definitions of autocorrelation? And that it also says that sometimes that term is used when autocovariance is meant (and provides a link to that site)? And how did you determine that the "results" are not the same?

    Also, you do know that "autocorr.m" (if that is what you have) is source code, right? You can read that with a text editor and implement that code in Java.

    Maybe the reference manual will help you reading it.

  9. #9
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default

    I implement the wiki way in method and test the result's in relation to those that the autocorr matlab function give as output with the same input series (vector) and there are not the same!!

    Regarding to .m file:

    "I try to see the .m file but since my matlab code knowledge isn't good i cant understand it!"

    I will try to improve my matlab code knowledge to understand the .m file and i will implement it in java.....

    I just hope that someone already do that and save some time but i guess not

    Anw Thanks for the reply again!!

  10. #10
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,019
    Blog Entries
    7
    Rep Power
    20

    Default

    Quote Originally Posted by Pericles View Post
    I implement the wiki way in method and test the result's in relation to those that the autocorr matlab function give as output with the same input series (vector) and there are not the same!!
    Maybe, just maybe your implementation is not correct; it took you about half an hour to implement it while probably Matlab's implementation was thoroughly tested ... just a guess ...

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

  11. #11
    masijade is offline Senior Member
    Join Date
    Jun 2008
    Posts
    2,571
    Rep Power
    8

    Default

    Quote Originally Posted by Pericles View Post
    I implement the wiki way in method and test the result's in relation to those that the autocorr matlab function give as output with the same input series (vector) and there are not the same!!
    In 17 minutes you not only saw the response, but read the wiki page(s) and coded and tested (not only comparing to the matlab results but also testing for accuracy) the results, and responded to the post. Wow! If you're that much of a genius coder it should be no problem to quickly figure out (with the help of the reference manual) how the matlab code works and implement it in Java.

  12. #12
    Pericles is offline Member
    Join Date
    Apr 2011
    Posts
    6
    Rep Power
    0

    Default

    Lol, dude take it easy,

    the wiki way is already implemented by me yesterday not know in just 17min :)

    What make you thought that i did it in 17min? :confused:

    Also there is a lot o chance to be wrong but this is the reason i have enter this forum for help and NOT for an attack from you guys :)

    Take it easy!!

    I said i wil check the .m file and i will find the answer..

    Thanks for the reply

Similar Threads

  1. run a matlab script from java
    By npoorni in forum Advanced Java
    Replies: 5
    Last Post: 02-11-2010, 03:32 PM
  2. Matlab data type implementation & speed
    By uzil24 in forum Advanced Java
    Replies: 3
    Last Post: 10-24-2009, 02:00 AM
  3. Loading a .dylib for Matlab Compiler STUCK!
    By jsparger in forum New To Java
    Replies: 3
    Last Post: 07-03-2009, 05:36 AM
  4. Help, Integrate a Java with Matlab
    By toby in forum Advanced Java
    Replies: 2
    Last Post: 08-07-2008, 07:08 AM
  5. Replies: 1
    Last Post: 08-07-2007, 05:37 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •