Hello, I have a time series sample of 4000 firms over 18 years period (2000-2017). I am trying to find a way to use the daily returns in order to estimate the annual beta for each stock. I am unsure of what code to use. Any advice or guidance on how to structure my SAS code is highly appreciated. (SAS version 9.4) My data is structured as follows: PERMCO DATE COMPANY_NAME RETURN MARKET_RETURN YEAR PERMCO&YEAR 153 2000-02-01 -0.15 2000 1532000 153 2000-02-02 0.1 2000 153 2000-02-03 0.2 2000 153 . . . 153 2017-12-28 674 674 674 . . . 2114 2114 211 etc... I would like the output to look something like shown below: (1 beta for each stock per year) PERMCO YEAR BETA 153 2000 153 2001 153 2002 674 2015 2114 2017 etc... Thank you
... View more