Sorting portfolios based on criteria (top30%,Middle 40%. and Bottom 30%)
问题 Currently, I have the following table Company---------Date--------Exchange-------Size A---------------2000---------A-------------50 A---------------2001---------A------------ 100 B---------------2000---------B------------450 B---------------2001---------B------------- 458 I want to allocate each company into three categories "Top" ==> Top 30% "Middle" ==> Middle 40% "Bottom" ==> Bottom 30% Calculating cutoff values should be filtered with 'year' and 'Exchange'=A I have tried the following