No BSD License  

4.54545

4.5 | 11 ratings Rate this file 39 Downloads (last 30 days) File Size: 5.18 KB File ID: #4325
image thumbnail

Rescaled Range Analysis

by

 

01 Jan 2004 (Updated )

Calculates the rescaled range analysis.

| Watch this File

File Information
Description

Accorting to the references the Rescaled Range Analysis can reveal non-periodic cycles time series. It has found many applications on the financial time series, although the underlying theory is not convincing. This m-file contains the basic algorithm and 4 proposed variations. The estimation of the Hurst exponents is up to the user.

MATLAB release MATLAB 6.5 (R13)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (16)
17 Dec 2013 BAPPA MUKHERJEE

thanks

05 Feb 2013 maryam mohamadi

thanksssssssss
very much

19 Jun 2012 Eva

Please help me! could somebody please explain me shortly how does it works? I am new at matlab so it is dificult for me, but I need to calcule some time series by this method, hope You will help me.

Best regards
Eva

29 Oct 2011 Lars

I'm having some issues producing an output. Am I supposed to remove some ; or something? My intentions are to make a log(RS) log(n) plot. The program only yields a single number which doesn't make any sense.

Any help much appreciated.

-Lars

17 Feb 2011 Joris

Thanks for the function.

The case when x(t)=0 for some period greater than the length of a block should be treat separately, if not it gives a 0/0 division.

How to compute the lag time vector to plot the pox plot of R/S ? I try lag(i)=log10(N/n(i)) but it gives strange result (decreasing function...)

Help !

And Thks !
Joris

14 Feb 2008 ali gezer  
01 Jan 2008 SUNGKONO HANANING

i'm studend in ITS (Institut teknologi sepuluh Nopember) Surabaya in Indonesia.
i'm interest to sdudied fractal (mono and multi) analysis for well-log analysis.

thank's for this source code.

15 Nov 2007 Matt Peloso

Needs some small fixes, I gave it simulated fBm time series and put them in the routine, but the slopes did not evaluate to the H exponent. I found that the routine is missing the first step taking log(Ni+1/Ni) of the time series. Also, autocorr(x,1) I replaced as xcorr(x)...maybe my version. Now it is giving meaningful data. Otherwise, a great reoutine and saves lots of time typing up the bulk of the code....THANKS!!!

26 Oct 2007 Chris Axioglou

Very useful! Just a notice (at least for the Lo method): the variation seems to be the unbiased one (i.e. the cross-product sums are divided by the degrees of freedom, instead of the full period length).

13 Dec 2006 Thomas A. Thiele

I forgot to mention one thing: If you wish to compute the log E(R/S) using the Anis and Lloyd (1976) formula, you may use the following code at line 190:

logERS(i,1)=log10((gamma(0.5*(n(i)-1))/(sqrt(pi)*gamma(.5*n(i))))*s)

However, for n < 340 the gamma value become to large and might not give you an estimate. I therefore suggest to switch to Peters' formula for n<340.

Thomas

02 Dec 2006 ZC huang

nice

14 Sep 2006 Thomas A. Thiele

The program calculates the rescaled range, the expected value, and the V-statistic. One just needs to determine the cycle length (if any) and set up the regression accordingly. The slope of the regression equation is the Hurst exponent.

With the expected value for R/S, one can easily test the significance of the results.

Overall a very good and handy routine.

Thomas

07 Dec 2005 Gabbar Singh  
08 Feb 2005 Vahidin Jeleskovic  
25 Aug 2004 wai wl  
26 Mar 2004 haoqm qm  

Contact us