<?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: How to balance the &amp;quot;unbalanced data&amp;quot; and transpose the format in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172065#M301570</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's pretty neat, thank you so much!&lt;/P&gt;&lt;P&gt;By the way, is there any easy way to do step 1? (I mean, balance the data but don't transpose the format)... Looks like I can re-transpose the data after running your code, am I right?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 24 May 2014 16:25:11 GMT</pubDate>
    <dc:creator>Jonate_H</dc:creator>
    <dc:date>2014-05-24T16:25:11Z</dc:date>
    <item>
      <title>How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172063#M301568</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;I have unbalanced data: each ID in each year have different number of observations (in total 12 years and 50 different IDs).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;I try to:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;step 1, make each ID in each year have the same number of observations (6 obs/year), and set income as missing value for those missing months.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;step 2, transpose the format of the "balanced" data set.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;(for step 1, I tried to split data into small ones by id and by year, operate on each small data set, and then merge them back (the &lt;SPAN style="line-height: 1.5em;"&gt;process is very inefficient); for step 2, I find something about "proc transpose" on the website is relevant, but haven't found &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5em;"&gt;the right way to do it)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="6428" alt="unbalanced.png" class="jive-image-thumbnail jive-image" src="https://communities.sas.com/legacyfs/online/6428_unbalanced.png" width="450" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 May 2014 15:40:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172063#M301568</guid>
      <dc:creator>Jonate_H</dc:creator>
      <dc:date>2014-05-24T15:40:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172064#M301569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can perform both of these steps using PROC TRANSPOSE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc transpose data=have out=want;&lt;/P&gt;&lt;P&gt;by year month;&lt;/P&gt;&lt;P&gt;var income;&lt;/P&gt;&lt;P&gt;id id;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 May 2014 15:57:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172064#M301569</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2014-05-24T15:57:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172065#M301570</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's pretty neat, thank you so much!&lt;/P&gt;&lt;P&gt;By the way, is there any easy way to do step 1? (I mean, balance the data but don't transpose the format)... Looks like I can re-transpose the data after running your code, am I right?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 May 2014 16:25:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172065#M301570</guid>
      <dc:creator>Jonate_H</dc:creator>
      <dc:date>2014-05-24T16:25:11Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172066#M301571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You could transpose the data back again, yes.&amp;nbsp; You could write a datastep to do it, but I do not really see the benefit of having that intermediate data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 May 2014 21:10:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172066#M301571</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2014-05-24T21:10:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172067#M301572</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You're right. Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 May 2014 21:30:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/172067#M301572</guid>
      <dc:creator>Jonate_H</dc:creator>
      <dc:date>2014-05-24T21:30:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/256950#M301573</link>
      <description>&lt;P&gt;Hi FriedEgg,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on an analysis that needs me to get the intermediate data, that is, only conduct Step 1 in the original post. Do you know how I can do that?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Mar 2016 03:56:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/256950#M301573</guid>
      <dc:creator>MY_</dc:creator>
      <dc:date>2016-03-16T03:56:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/257094#M301574</link>
      <description>&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/77697"&gt;@MY_&lt;/a&gt; it would serve you best to create a new post specific to your question.</description>
      <pubDate>Wed, 16 Mar 2016 18:33:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/257094#M301574</guid>
      <dc:creator>FriedEgg</dc:creator>
      <dc:date>2016-03-16T18:33:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to balance the "unbalanced data" and transpose the format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/257095#M301575</link>
      <description>&lt;P&gt;Hi FriedEgg,&amp;nbsp;I have sent SAS support an email and got the answers. Thank you for your kindly reply &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 Mar 2016 18:36:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-balance-the-quot-unbalanced-data-quot-and-transpose-the/m-p/257095#M301575</guid>
      <dc:creator>MY_</dc:creator>
      <dc:date>2016-03-16T18:36:55Z</dc:date>
    </item>
  </channel>
</rss>

