<?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 creating a vector in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88297#M18828</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;BR /&gt;Below is a small sample of a large data set. &lt;/P&gt;&lt;P&gt;Firmid year segmentID segmentsales siccode&lt;BR /&gt;1001 1999 1 20 4100&lt;BR /&gt;1001 1999 2 10 4200&lt;BR /&gt;1001 2000 1 15 4100&lt;BR /&gt;1001 2000 2 12 4200&lt;BR /&gt;1001 2000 3 13 5100&lt;BR /&gt;1002 1999 1 20 4100&lt;BR /&gt;1002 1999 2 13 9100&lt;BR /&gt;1002 2001 1 20 2867&lt;BR /&gt;1002 2001 2 13 3200&lt;BR /&gt;1002 2000 3 20 7100&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. First, I can compute how many unique siccode my data has, in this small example above, I have 7 unique siccode&lt;BR /&gt;2. my vector will have 7 elements, each element correspond to the segmentsales, for each firm-year, there are non-zero segmentsales and zero segmentsales&amp;nbsp; (when the firm does not have such a segment), e.g. firmid=1001, year=1999, my vector =[20,10,0,0,0,0,0], firmid=1001, year=2000, my vector =[15,12,13,0,0,0]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How should I program this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;Lan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 25 Mar 2013 21:22:10 GMT</pubDate>
    <dc:creator>LanMin</dc:creator>
    <dc:date>2013-03-25T21:22:10Z</dc:date>
    <item>
      <title>creating a vector</title>
      <link>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88297#M18828</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;BR /&gt;Below is a small sample of a large data set. &lt;/P&gt;&lt;P&gt;Firmid year segmentID segmentsales siccode&lt;BR /&gt;1001 1999 1 20 4100&lt;BR /&gt;1001 1999 2 10 4200&lt;BR /&gt;1001 2000 1 15 4100&lt;BR /&gt;1001 2000 2 12 4200&lt;BR /&gt;1001 2000 3 13 5100&lt;BR /&gt;1002 1999 1 20 4100&lt;BR /&gt;1002 1999 2 13 9100&lt;BR /&gt;1002 2001 1 20 2867&lt;BR /&gt;1002 2001 2 13 3200&lt;BR /&gt;1002 2000 3 20 7100&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. First, I can compute how many unique siccode my data has, in this small example above, I have 7 unique siccode&lt;BR /&gt;2. my vector will have 7 elements, each element correspond to the segmentsales, for each firm-year, there are non-zero segmentsales and zero segmentsales&amp;nbsp; (when the firm does not have such a segment), e.g. firmid=1001, year=1999, my vector =[20,10,0,0,0,0,0], firmid=1001, year=2000, my vector =[15,12,13,0,0,0]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How should I program this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;Lan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Mar 2013 21:22:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88297#M18828</guid>
      <dc:creator>LanMin</dc:creator>
      <dc:date>2013-03-25T21:22:10Z</dc:date>
    </item>
    <item>
      <title>Re: creating a vector</title>
      <link>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88298#M18829</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you programming in IML or BASE? If IML you may want to repost this in the IML forum.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Mar 2013 22:39:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88298#M18829</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2013-03-25T22:39:44Z</dc:date>
    </item>
    <item>
      <title>Re: creating a vector</title>
      <link>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88299#M18830</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I do not know how to program in IML.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Mar 2013 03:13:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/creating-a-vector/m-p/88299#M18830</guid>
      <dc:creator>LanMin</dc:creator>
      <dc:date>2013-03-26T03:13:59Z</dc:date>
    </item>
  </channel>
</rss>

