I need to generate a variable representing the correlation between variables x and y, for different countries and years. I want to store that variable in my dataset. There was a thread on this in 2008, where it was suggested that I this would work ssc install egenmore egenmore corrxy = corr(x,y) , by(country year) For me, though, that doesn't work. The ssc installation appears to run OK, but the next command generates an error "unrecognized command: egenmore" If instead I type egen corrxy = corr(x,y) , by(country year) I get a different error: "invalid syntax". If I type help egenmore I get a help page for the egen command, which contains no description of a corr() function.
-
Login or Register
- Log in with
Comment