<?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 Calculate difference in ratio/proportions between two survey samples using proc surveymeans in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Calculate-difference-in-ratio-proportions-between-two-survey/m-p/386647#M20115</link>
    <description>&lt;P&gt;I can do this for&amp;nbsp;difference in weighted frequencies by making the previous month's employment variable negative (-1) and the current month's employment variable positive (+1), which produces the net sample-to-sample change in the variable "employed", as well as the CV. But I&amp;nbsp;don't know how to do it for ratios (for example the total rate of employment).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;data output.newcombined ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;set output.combined;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if employed=1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if sampledate in (previousmonth) then changeemployed= -1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if sampledate in (currentmonth) &amp;nbsp;then changeemployed= &amp;nbsp;1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;run;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;proc surveymeans data=output.newcombined varmethod=brr clm nobs mean median CV&amp;nbsp; cvwt SUMWGT Sum CVSum CLSum&amp;nbsp; alpha=&lt;FONT color="teal"&gt;&lt;STRONG&gt;0.32&lt;/STRONG&gt;&lt;/FONT&gt;;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var changeemployed;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; weight finalwt ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; repweights bw1-bw1000 ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;run ;&lt;/FONT&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 09 Aug 2017 14:17:02 GMT</pubDate>
    <dc:creator>fieldsa83</dc:creator>
    <dc:date>2017-08-09T14:17:02Z</dc:date>
    <item>
      <title>Calculate difference in ratio/proportions between two survey samples using proc surveymeans</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Calculate-difference-in-ratio-proportions-between-two-survey/m-p/386647#M20115</link>
      <description>&lt;P&gt;I can do this for&amp;nbsp;difference in weighted frequencies by making the previous month's employment variable negative (-1) and the current month's employment variable positive (+1), which produces the net sample-to-sample change in the variable "employed", as well as the CV. But I&amp;nbsp;don't know how to do it for ratios (for example the total rate of employment).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;data output.newcombined ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;set output.combined;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if employed=1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if sampledate in (previousmonth) then changeemployed= -1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;if sampledate in (currentmonth) &amp;nbsp;then changeemployed= &amp;nbsp;1;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;run;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;proc surveymeans data=output.newcombined varmethod=brr clm nobs mean median CV&amp;nbsp; cvwt SUMWGT Sum CVSum CLSum&amp;nbsp; alpha=&lt;FONT color="teal"&gt;&lt;STRONG&gt;0.32&lt;/STRONG&gt;&lt;/FONT&gt;;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var changeemployed;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; weight finalwt ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; repweights bw1-bw1000 ;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="Courier New"&gt;run ;&lt;/FONT&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 09 Aug 2017 14:17:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Calculate-difference-in-ratio-proportions-between-two-survey/m-p/386647#M20115</guid>
      <dc:creator>fieldsa83</dc:creator>
      <dc:date>2017-08-09T14:17:02Z</dc:date>
    </item>
    <item>
      <title>Re: Calculate difference in ratio/proportions between two survey samples using proc surveymeans</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Calculate-difference-in-ratio-proportions-between-two-survey/m-p/386699#M20135</link>
      <description>&lt;P&gt;I'm not really clear on what you are attempting to do. Are attempting to compare between to groups of records? That might mean you want a DOMAIN analysis to generate the summaries for the two groups and then examine the results.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is your employed variable a 0/1 dichotomous to indicate a status? then perhaps that varaible should be the VAR and Sampledate or your changeemployed as DOMAIN variables.&lt;/P&gt;</description>
      <pubDate>Wed, 09 Aug 2017 16:24:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Calculate-difference-in-ratio-proportions-between-two-survey/m-p/386699#M20135</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2017-08-09T16:24:20Z</dc:date>
    </item>
  </channel>
</rss>

