小编Dim*_*ima的帖子

Calculate within correlation in panel data long form

We have a simple panel data set in long form, which has the following structure:

i   t            x
1   Aug-2011     282
2   Aug-2011    -220
1   Sep-2011     334
2   Sep-2011     126
1   Sep-2012    -573
2   Sep-2012     305
1   Nov-2013     335
2   Nov-2013     205
3   Nov-2013     485
Run Code Online (Sandbox Code Playgroud)

I would like to get the cross-correlation between each i within the time-variable t.

This would be possible by converting the data in wide format. Unfortunately, this approach is not feasible due to the …

panel correlation stata cross-correlation panel-data

2
推荐指数
1
解决办法
493
查看次数