<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Creating portfolios based on a number/category in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513491#M138359</link>
    <description>So given what you've shown, what would you expect as output? It's helps if you can be more specific with your question.</description>
    <pubDate>Thu, 15 Nov 2018 17:54:26 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2018-11-15T17:54:26Z</dc:date>
    <item>
      <title>Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513484#M138354</link>
      <description>&lt;P&gt;The first day of using SAS so please bear with me if I ask the question in the wrong way etc.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a list of companies and I would like to create portfolios (equally weighted) for each month.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I currently have the data in excel and this is how the sheet is set up (in case this helps):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Company Name Trading Year Trading Month Category Total Market Value Return Div Return No Div&lt;BR /&gt;China Baoan Group Co., Ltd. 1991 6 1 1080144&lt;BR /&gt;China Baoan Group Co., Ltd. 1991 7 1 787605 -0.270833 -0.270833&lt;BR /&gt;Gintian Industry (Group) Co., Ltd. 1991 7 2 222124.92&lt;BR /&gt;China Baoan Group Co., Ltd. 1991 8 1 810108 0.028571 0.028571&lt;BR /&gt;Gintian Industry (Group) Co., Ltd. 1991 8 2 211445.83 -0.048077 -0.048077&lt;BR /&gt;China Baoan Group Co., Ltd. 1991 9 1 798856.5 -0.013889 -0.013889&lt;BR /&gt;Gintian Industry (Group) Co., Ltd. 1991 9 2 200766.75 -0.050505 -0.050505&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And the list continues down from 1991 until 2017 with lots of companies.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to create portfolios based on each of the categories, i.e. value-weighted returns for all of the companies in Category 1, 2, etc. (There are 6 categories in total).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, the portfolio is set up every year in June (trading month 6), if and only if, there is no missing return data in June. Then there is a buy and hold strategy, where I used the market weights based on June of each year and then the investment weights are based on the returns. Then every June the portfolios are rebalanced.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In a similar way to Kenneth Frenches portfolios if anyone has experience with them.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance if anyone can help.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Tony&lt;/P&gt;</description>
      <pubDate>Thu, 15 Nov 2018 17:47:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513484#M138354</guid>
      <dc:creator>TonyChivers</dc:creator>
      <dc:date>2018-11-15T17:47:37Z</dc:date>
    </item>
    <item>
      <title>Re: Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513491#M138359</link>
      <description>So given what you've shown, what would you expect as output? It's helps if you can be more specific with your question.</description>
      <pubDate>Thu, 15 Nov 2018 17:54:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513491#M138359</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-11-15T17:54:26Z</dc:date>
    </item>
    <item>
      <title>Re: Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513509#M138363</link>
      <description>I would like the value weighted return for each category for each month.&lt;BR /&gt;</description>
      <pubDate>Thu, 15 Nov 2018 18:37:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513509#M138363</guid>
      <dc:creator>TonyChivers</dc:creator>
      <dc:date>2018-11-15T18:37:10Z</dc:date>
    </item>
    <item>
      <title>Re: Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513606#M138391</link>
      <description>&lt;P&gt;If I have 6 categories, I would like the value-weighted return for each category for each month of the year.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To try and be more clear on the question.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to define each portfolio in June of each year.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Lets take 1991 as an example.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If there are 10 stocks in June in 1991, and 4 of them have missing return data in June, then I would include them six stocks in the portfolio for one year.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then next June, I will create a new portfolio, which will again include all the stocks in June 1992 that dont have missing data.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The amount I invest in each stock is based on its market capitalization for June and then it will change depending on the returns in the following months, until next June, when I will rely on the market cap again.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So in effect the portfolios are created and rebalanced every June.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If a stock appears later in the year, say it gets listed in December, and it wasn't around in June, I don't care for it and it will only be included in the following year, the June immediately after the December it was listed.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Does this make it any clearer?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Nov 2018 21:00:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513606#M138391</guid>
      <dc:creator>TonyChivers</dc:creator>
      <dc:date>2018-11-15T21:00:07Z</dc:date>
    </item>
    <item>
      <title>Re: Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513612#M138394</link>
      <description>&lt;P&gt;Not really and unfortunately not something I have time to sort out today. Hopefully someone else can help. I do know that if you provide a clear starting point, here's what I have, here's what I want - output that matches your input and a description of the logic you'll likely get an answer very quickly. But trying to determine that and test the different requirements is something I cannot make the time for today. Hopefully someone else can help you out. Perhaps&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/138205"&gt;@novinosrin&lt;/a&gt;&amp;nbsp;when he has some time.&lt;/P&gt;</description>
      <pubDate>Thu, 15 Nov 2018 21:05:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513612#M138394</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-11-15T21:05:19Z</dc:date>
    </item>
    <item>
      <title>Re: Creating portfolios based on a number/category</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513645#M138410</link>
      <description>Thanks for your help anyway.&lt;BR /&gt;</description>
      <pubDate>Thu, 15 Nov 2018 21:29:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Creating-portfolios-based-on-a-number-category/m-p/513645#M138410</guid>
      <dc:creator>TonyChivers</dc:creator>
      <dc:date>2018-11-15T21:29:10Z</dc:date>
    </item>
  </channel>
</rss>

