Re: Circular statistics in IDL [message #94019 is a reply to message #94012] |
Wed, 21 December 2016 09:25   |
Craig Markwardt
Messages: 1869 Registered: November 1996
|
Senior Member |
|
|
On Tuesday, December 20, 2016 at 11:05:03 AM UTC-5, Gadi Goelman wrote:
> On Tuesday, December 13, 2016 at 6:10:30 PM UTC+2, Dick Jackson wrote:
>> On Tuesday, 13 December 2016 01:20:14 UTC-8, Gadi Goelman wrote:
>>> Does any one know if there is a circular statistics tool in IDL similar to the CircStat in Matlab? or any other tool to work with complex numbers
>>>
>>> Thanks
>>>
>>> Gadi
>>
>> Hi Gadi,
>>
>> I haven't seen an IDL library available, but when I needed some circular statistics (a.k.a. directional statistics) I wrote that up myself. What I did computed the mean, variance and standard deviation.
>>
>> The CircStat library certainly is comprehensive:
>> https://github.com/circstat/circstat-matlab
>>
>> How much of that functionality do you think you will need?
>>
>> Cheers,
>> -Dick
>>
>> Dick Jackson Software Consulting Inc.
>> Victoria, BC, Canada --- http://www.d-jackson.com
>
> Thanks Dick
> What I need is to calculate significance of complex numbers or phases. Do you know if correct calculations of mean, variance etc is sufficient? I guess that you cant assume normal distributions and different distributions are needed such circular Gaussian.
I'm a big fan of the Rayleigh (Z) statistic. It's pretty easy to calculate. For an array of unit complex number U, it's
Z = total(abs(U)^2)
In the case of the null hypothesis (only noise), the Z statistic is distributed as a chi-square with 2 degrees of freedom. You you can use IDL's chi-square statistic to test statistical significance, or my equivalent MPCHITEST() function.
Craig
|
|
|