Ranking Data and form portfolios

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason

lhu022
Posts: 1
Joined: Wed Sep 12, 2012 1:27 pm

Ranking Data and form portfolios

Postby lhu022 » Wed Sep 12, 2012 1:44 pm

Hi:

I have 100 firms stock returns and some kind of beta coefficients of each firm ; monthly data for 30 years.
Some returns are NAs.

My task is:
1)For each month, ranking betas from low to high, form 10 portfolios. Each portfolio has 10 stocks (if the stock return is not NAs). But if there are some NA for stock returns then ignore that stock. For example, for a month, 10 stock returns are NAs, then each portfolio will have 9 stocks instead of 10.
2)find the simple average returns of each portfolio in each monthly.
3) find the simple average returns of the bottom 5 portfolio and top 5 portfolio
4) form a factor loading such like market factor SMB

The last 2 steps are easy, but I have a big problem to process the first 2 steps

Could anyone please kind help out?

Thank you so much

Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 2 guests