Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Rolling correlation coefficients with panel data


From   Alexandre Athanassiadis <msf11aa3@mail.wbs.ac.uk>
To   statalist@hsphsun2.harvard.edu
Subject   st: Rolling correlation coefficients with panel data
Date   Sat, 1 Sep 2012 22:45:30 +0100

Dear All,


I hope you are well.

In the context of my research, I am using a rather large dataset (730
corporates, their daily stock price for the 2003-2011 period and the
risk free rate for the same period). Among other things, I am trying
to compute the rolling correlation coefficients of the stock prices
with the risk free rate.

I have declared the data to be 'panel' without any difficulties:
- egen id=group(tic)
- xtset id Date, daily

and I am using the following line to compute the correlation coefficients:
- rolling, window(20) clear; corr price rate

Unfortunately it take ages to get the job done! Any ideas on how I
could improve my method?

Thank you very much for your help,

Regards,

Alexandre
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index