<?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: Using weighted frequencies for NHANES data in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Using-weighted-frequencies-for-NHANES-data/m-p/869161#M38436</link>
    <description>&lt;P&gt;The weighted data for each survey is supposed to yield a total population estimate. When you combine x number of surveys you will get roughly x*the population total.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You have to figure out the contribution of each cycle (i.e. total weight) and adjust as a proportion of the desired population year.&lt;/P&gt;
&lt;P&gt;Likely by one or more population characteristics such as age, sex and geography. As a minimum they should be the Strata and Cluster variables. And hope the cluster definitions are the same or you have to standardize your data to one of the clusters so the data can be combined correctly.&lt;/P&gt;
&lt;P&gt;You should pick one of the years as the standard to adjust to. There's a number of arguments about whether to use the middle value, if available vs the end points.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are some details specific to NHANES at &lt;A href="https://wwwn.cdc.gov/nchs/nhanes/tutorials/Weighting.aspx" target="_blank" rel="noopener"&gt;https://wwwn.cdc.gov/nchs/nhanes/tutorials/Weighting.aspx&lt;/A&gt; that specifically mentions multiple cycles. Follow the links.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Google may be your friend sometimes.&lt;/P&gt;</description>
    <pubDate>Thu, 20 Apr 2023 21:34:30 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2023-04-20T21:34:30Z</dc:date>
    <item>
      <title>Using weighted frequencies for NHANES data</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Using-weighted-frequencies-for-NHANES-data/m-p/869158#M38435</link>
      <description>&lt;P&gt;I am looking to construct a weight for combined surveys using NHANES data, I am combining 6 survey cycles&lt;/P&gt;&lt;P&gt;I created a new weight variable using this code&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;****Construct weight for combined surveys;
data nh1.basedata ;
set nh1.basedata;
if sddsrvyr=5 or sddsrvyr=6 or sddsrvyr=7 or sddsrvyr=8 or sddsrvyr=9 or sddsrvyr=10 then Weightdiet12YR=1/6*WTDRD1;
run;&amp;nbsp;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;when using the weight value in order to generate frequencies for categorical variables the weighted frequency results it an extremely large number. for example for gender (results table is below)&lt;/P&gt;&lt;P&gt;I have used proc surveyfreq for this&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;gender&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;frequency&lt;/TD&gt;&lt;TD&gt;weighted frequency&lt;/TD&gt;&lt;TD&gt;std err of wgt freq&lt;/TD&gt;&lt;TD&gt;percent&lt;/TD&gt;&lt;TD&gt;std err or percent&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;13265&lt;/TD&gt;&lt;TD&gt;96910369&lt;/TD&gt;&lt;TD&gt;2389194&lt;/TD&gt;&lt;TD&gt;47.9077&lt;/TD&gt;&lt;TD&gt;0.3588&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;TD&gt;14263&lt;/TD&gt;&lt;TD&gt;105375165&lt;/TD&gt;&lt;TD&gt;2517680&lt;/TD&gt;&lt;TD&gt;52.0923&lt;/TD&gt;&lt;TD&gt;0.3588&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;total&lt;/TD&gt;&lt;TD&gt;27528&lt;/TD&gt;&lt;TD&gt;202285535&lt;/TD&gt;&lt;TD&gt;4687511&lt;/TD&gt;&lt;TD&gt;100.0000&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;proc surveyfreq data=nh1.basedata1 nomcar;
tables RIAGENDR age_cat PIR BMICAT SMOKECAT;
strata sdmvstra;
cluster sdmvpsu;
weight Weightdiet12YR;
where select=2;
run;&lt;/PRE&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;DIV align="center"&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;DIV align="center"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;Is proc surveyfreq the best method?&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to I fix the error with the weighted frequency, is it an issue with how the weight is calculated&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!!!&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV align="center"&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 11 Apr 2023 17:01:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Using-weighted-frequencies-for-NHANES-data/m-p/869158#M38435</guid>
      <dc:creator>byrne48</dc:creator>
      <dc:date>2023-04-11T17:01:02Z</dc:date>
    </item>
    <item>
      <title>Re: Using weighted frequencies for NHANES data</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Using-weighted-frequencies-for-NHANES-data/m-p/869161#M38436</link>
      <description>&lt;P&gt;The weighted data for each survey is supposed to yield a total population estimate. When you combine x number of surveys you will get roughly x*the population total.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You have to figure out the contribution of each cycle (i.e. total weight) and adjust as a proportion of the desired population year.&lt;/P&gt;
&lt;P&gt;Likely by one or more population characteristics such as age, sex and geography. As a minimum they should be the Strata and Cluster variables. And hope the cluster definitions are the same or you have to standardize your data to one of the clusters so the data can be combined correctly.&lt;/P&gt;
&lt;P&gt;You should pick one of the years as the standard to adjust to. There's a number of arguments about whether to use the middle value, if available vs the end points.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are some details specific to NHANES at &lt;A href="https://wwwn.cdc.gov/nchs/nhanes/tutorials/Weighting.aspx" target="_blank" rel="noopener"&gt;https://wwwn.cdc.gov/nchs/nhanes/tutorials/Weighting.aspx&lt;/A&gt; that specifically mentions multiple cycles. Follow the links.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Google may be your friend sometimes.&lt;/P&gt;</description>
      <pubDate>Thu, 20 Apr 2023 21:34:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Using-weighted-frequencies-for-NHANES-data/m-p/869161#M38436</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2023-04-20T21:34:30Z</dc:date>
    </item>
  </channel>
</rss>

