I am getting a "not sorted error" when attempting to run a time series regression for different "styles" (ie different categories) of funds. Any suggestions on applying the bysort would be appreciated - or suggestions on alternative approaches to conducting the exercise would also be appreciated. Thank you, Dan
The data looks like
and the code for running the regressions across styles is
(there are other funds in the full data set - ie some which are not retail and other types of style - but I hope this sample of the data helps set out the idea) thanks again, Dan
The data looks like
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input long id float month str1 retail_fund str4 style float(age ff size) 90727 696 "Y" "EDYG" 10 .47116 -.5108256 90727 697 "Y" "EDYG" 11 -.1180397 -.6931472 90727 698 "Y" "EDYG" 12 .41804 -.356675 90727 699 "Y" "EDYG" 13 .13305917 -.22314353 90727 700 "Y" "EDYG" 14 -.023651 -.22314353 90727 701 "Y" "EDYG" 15 -.001185 -.22314353 90913 696 "Y" "EDYG" 10 .12215516 2.6602595 90913 697 "Y" "EDYG" 11 .0046509327 2.631889 90913 698 "Y" "EDYG" 12 .103537 2.714695 90913 699 "Y" "EDYG" 13 .07039671 2.785011 90913 700 "Y" "EDYG" 14 .015616804 2.827314 90913 701 "Y" "EDYG" 15 .03278398 2.862201 end format %tmYYMon month
Code:
bysort style: xtreg ff L.ff size age if retail_fund=="Y", re

Comment