<?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: proc gchart, creating age distributions of employment in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/proc-gchart-creating-age-distributions-of-employment/m-p/26461#M6039</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Without seeing your source data I've made some assumptions about what it looks like, but the below should do what you need:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data manu_agedist;&lt;/P&gt;&lt;P&gt;format agegrp $10.;&lt;/P&gt;&lt;P&gt;format emp 8.;&lt;/P&gt;&lt;P&gt;infile datalines dsd;&lt;/P&gt;&lt;P&gt;input agegrp $ emp;&lt;/P&gt;&lt;P&gt;datalines;&lt;/P&gt;&lt;P&gt;18-25,500&lt;/P&gt;&lt;P&gt;26-29,250&lt;/P&gt;&lt;P&gt;30-36,333&lt;/P&gt;&lt;P&gt;37-44,123&lt;/P&gt;&lt;P&gt;45-54,999&lt;/P&gt;&lt;P&gt;55-64,40&lt;/P&gt;&lt;P&gt;65+,5&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc gchart data=manu_agedist;&lt;/P&gt;&lt;P&gt;vbar agegrp / discrete type=percent freq=emp;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc tabulate data=manu_agedist;&lt;/P&gt;&lt;P&gt;class agegrp;&lt;/P&gt;&lt;P&gt;var emp;&lt;/P&gt;&lt;P&gt;table agegrp, colpctsum*emp;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Jul 2011 13:22:22 GMT</pubDate>
    <dc:creator>DF</dc:creator>
    <dc:date>2011-07-07T13:22:22Z</dc:date>
    <item>
      <title>proc gchart, creating age distributions of employment</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-gchart-creating-age-distributions-of-employment/m-p/26460#M6038</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a variable (agegrp) that is an age interval identifier.&amp;nbsp; Values of agegrp would look something like 14-18, 19-21, etc.&amp;nbsp; My second variable is a count of employment (emp) that corresponds to agegrp identifiers.&amp;nbsp; I am trying to create a histogram that is an age distribution of employment.&amp;nbsp; I'd like to graph an age distribution with each series the share of total employment x agegrp.&amp;nbsp; On the y-axis would be percent of total employment and the agegrp identifiers on the x-axis.&amp;nbsp; The code I have so far is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc gchart data=manu_agedist(where=(time="1995:1"));&lt;/P&gt;&lt;P&gt;vbar agegrp / dsicrete type=percent&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sumvar=emp sum;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code yields counts of employment on the y-axis and agegrps on the x-axis.&amp;nbsp; Does anyone have advice on how to fix my code so I can graph an age distribution with each series the share of total employment x agegrp?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jul 2011 15:58:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-gchart-creating-age-distributions-of-employment/m-p/26460#M6038</guid>
      <dc:creator>jdub</dc:creator>
      <dc:date>2011-07-06T15:58:15Z</dc:date>
    </item>
    <item>
      <title>Re: proc gchart, creating age distributions of employment</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-gchart-creating-age-distributions-of-employment/m-p/26461#M6039</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Without seeing your source data I've made some assumptions about what it looks like, but the below should do what you need:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data manu_agedist;&lt;/P&gt;&lt;P&gt;format agegrp $10.;&lt;/P&gt;&lt;P&gt;format emp 8.;&lt;/P&gt;&lt;P&gt;infile datalines dsd;&lt;/P&gt;&lt;P&gt;input agegrp $ emp;&lt;/P&gt;&lt;P&gt;datalines;&lt;/P&gt;&lt;P&gt;18-25,500&lt;/P&gt;&lt;P&gt;26-29,250&lt;/P&gt;&lt;P&gt;30-36,333&lt;/P&gt;&lt;P&gt;37-44,123&lt;/P&gt;&lt;P&gt;45-54,999&lt;/P&gt;&lt;P&gt;55-64,40&lt;/P&gt;&lt;P&gt;65+,5&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc gchart data=manu_agedist;&lt;/P&gt;&lt;P&gt;vbar agegrp / discrete type=percent freq=emp;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc tabulate data=manu_agedist;&lt;/P&gt;&lt;P&gt;class agegrp;&lt;/P&gt;&lt;P&gt;var emp;&lt;/P&gt;&lt;P&gt;table agegrp, colpctsum*emp;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jul 2011 13:22:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-gchart-creating-age-distributions-of-employment/m-p/26461#M6039</guid>
      <dc:creator>DF</dc:creator>
      <dc:date>2011-07-07T13:22:22Z</dc:date>
    </item>
  </channel>
</rss>

